~maas-maintainers/maas/qa-lab-tests_cleanup

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
Some tips for the developer
===========================

This document exists so developers can write tips for other developers
who need to add or fix tests to this environment.

In a nutshell
-------------

The script `maas-package-test` calls nosetest3, which, in turn, runs
`maas-integration.py`.


Pausing the test
----------------

The `utils.py` file contains a handy function, `pause_until_released`,
that writes a message to `/tmp/paused` and waits until the file is
deleted. It can be used to pause the test program at any given time so
you can ssh into the machine and inspect it. Another neat trick you can
do is to stop the program before any test runs. You can then run the
tests (and change the test-integration.py file to suit your needs). From
a folder named like `/tmp/adt-run.Ezz1tN/build.mM6/real-tree`, run
`nosetests3 --verbose --stop debian/tests/maas-integration.py` to start
it.