1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-12 09:18:10 +03:00
samba-mirror/ctdb/tests/eventscripts
Martin Schwenke 9f98ec85d9 Revert "Tests: tweak some samba tests to cope with debug from ctdb_check_tcp_ports()."
This reverts commit 557ac30e60516742da10b83bfbbbb41430c977a2.

(This used to be ctdb commit 9600cc7a6b7b854fac1a5b080129e3df8fcbd84e)
2011-08-11 15:32:28 +10:00
..
etc Tests: initial eventscript unit tests. 2011-08-08 13:38:07 +10:00
etc-ctdb Tests: initial eventscript unit tests. 2011-08-08 13:38:07 +10:00
simple Revert "Tests: tweak some samba tests to cope with debug from ctdb_check_tcp_ports()." 2011-08-11 15:32:28 +10:00
stubs Tests - implement "ctdb -Y ip -v" in stub for eventscript testing. 2011-08-08 15:42:45 +10:00
common.sh Tests: update tests to work with previous commit. 2011-08-08 13:47:13 +10:00
README Tests: initial eventscript unit tests. 2011-08-08 13:38:07 +10:00
run_tests.sh Tests: initial eventscript unit tests. 2011-08-08 13:38:07 +10:00

eventscript unit tests
======================

This directory contains some eventscript unit tests for CTDB.  These
tests can be run as a non-privileged user.  There are a lot of stub
implementations of commands (located in bin/) used to make the
eventscripts think they're running against a real system.

Examples:

* ./run_tests.sh

  Run all tests, displaying minimal output.

* ./run_tests.sh -s

  Run all tests, displaying minimal output and a summary.

* ./run_tests.sh  -s simple/*.sh

  Run all the tests in the simple/ subdirectory.

* ./run_tests.sh -v -s

  Run all tests, displaying extra output and a summary.

* ./run_tests.sh -sq

  Run all tests, displaying only a summary.

* EVENTSCRIPTS_TESTS_TRACE="sh -x" \
    ./run_tests.sh simple/10.interface.startup.002.sh

  Run a test and have the eventscript itself run with "sh -x".  This
  will usually make a test fail because the (undesirable) trace output
  will be included with the output of the eventscript.  However, this
  is useful for finding out why a test might be failing.  You can just
  drop the "-x" (minimal command-line editing) to see if changes have
  made a test pass.

The simple/ subdirectory contains tests that exercise only a single
eventscript.  Another directory containing tests that exercise
interactions between eventscripts is coming soon...  :-)