[PATCH] CTDB test improvements
Amitay Isaacs
amitay at gmail.com
Tue Nov 6 01:19:30 UTC 2018
On Mon, Nov 5, 2018 at 11:50 AM Martin Schwenke via samba-technical
<samba-technical at lists.samba.org> wrote:
>
> 2 mains changes:
>
> * For integration testing ("simple" and "complex" test suites),
> CTDB daemons are now started at the beginning of each test and
> stopped at the end of each test
>
> This is true when running with local daemons and against a real
> cluster. A side-effect of this is obviously that after testing the
> cluster will now be down. This should not cause a problem because
> the tests already affect cluster availability.
>
> Individual tests can now be run without depending on special tests
> that start/stop the cluster. It is now also easier to loop a single
> test.
>
> Daemons were previously not restarted at the end of each "simple"
> test, so running that test suite now takes longer. The patch set
> includes a small amount of rationalisation of tests to avoid
> duplication and generally reduce the number of tests. More work is
> needed... but a reasonable compromise has already been made.
>
> * Starting and stopping of local daemons in the "simple" test suite has
> been factored out into a separate script called
> ctdb/tests/local_daemons.sh (installed as ctdb_local_daemons)
>
> This script has setup/start/stop commands that are used by the test
> suite, and can be used independently for hand testing/debugging. It
> also has an onnode command, which sets any variables required to run
> commands (e.g. ctdb status) against a cluster of local daemons for
> debugging. There is also a print-socket command to print the ctdbd
> socket being used by the designated nodes - this can be used by more
> extensive clustered Samba testing to help configured (for example)
> smbd instances against ctdbd instances.
>
> Note that this patch set depends on the other 2 that I have just posted
> (config improvements, various fixes).
>
> Please review and maybe push...
In patch "ctdb-tests: Add local_daemons.sh", fix the help text for -S.
In patch "ctdb-daemon: Do not fork when CTDB_TEST_MODE is set", do not
do boolean operations on integer variable. Please define interactive
variable as bool.
Amitay.
More information about the samba-technical
mailing list