From 50efcd8efbea41668c05dd5eb24af4a383d22799 Mon Sep 17 00:00:00 2001 From: nbm Date: Mon, 15 May 2006 13:29:04 +0000 Subject: [PATCH] All-in-one test runner. --- tests/runtests.php | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+), 0 deletions(-) create mode 100644 tests/runtests.php diff --git a/tests/runtests.php b/tests/runtests.php new file mode 100644 index 0000000..4092549 --- /dev/null +++ b/tests/runtests.php @@ -0,0 +1,27 @@ +GroupTest('Unit tests'); + $this->addTestFile('SQLFile/test_sqlfile.php'); + $this->addTestFile('cache/testCache.php'); + $this->addTestFile('config/testConfig.php'); + $this->addTestFile('document/testDocument.php'); + } + + function addTestFile($file) { + if (!KTUtil::isAbsolutePath($file)) { + $file = sprintf('%s/%s', dirname(__FILE__), $file); + } + return parent::addTestFile($file); + } +} + +$test = &new UnitTests(); +if (SimpleReporter::inCli()) { + exit ($test->run(new TextReporter()) ? 0 : 1); +} +$test->run(new HtmlReporter()); + -- libgit2 0.21.4