Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* tester.cc (main): Isolate test suites running simultaneously from
the same build directory, by adjusting run_dir and logfile. Do not delete the entire run_dir on startup; it suffices to delete each test directory as we get to it. Also, cosmetic changes: Reformat. Kill the nested try-block. Fix handling of informative_failure and std::exception; add catch-all clause too. Exit 0 if given --help. Use lua_setglobal where possible. * testlib.lua (tests): Now local to run_tests. (logfile): Starts out as nil. Set to a filename by tester.cc, and then to a real open file in run_tests. (test): Move to more logical place. (prepare_to_run_tests, prepare_to_enumerate_tests): New hook functions. (run_tests): Neutralize NLS environment variables and SSH_AUTH_SOCK here. Scan testdir for __driver__.lua and use that to establish the set of all tests. Call the new hook functions as appropriate. * testsuite.lua: Move all initialization logic to prepare_to_run_tests, so that evaluating this file just defines functions. No need to scan the test directory. * tester-testsuite.lua: Remove list of tests.
- Loading branch information
mtn-dev
committed
Jul 24, 2007
1 parent
d0788f7
commit 7d9a7ac
Showing
4 changed files
with
168 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,2 @@ | ||
|
||
-- we have very little to do here; just declare the directory of tests. | ||
testdir = srcdir.."/tester-tests" | ||
|
||
table.insert(tests, "isolated-1") | ||
table.insert(tests, "isolated-2") | ||
table.insert(tests, "cleanup-1") | ||
table.insert(tests, "cleanup-2") | ||
table.insert(tests, "remove-unwriteable") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters