runtests.php
1.5 KB
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?php
require_once('test.php');
class UnitTests extends TestSuite {
function UnitTests() {
$this->TestSuite('Unit tests');
// KTAPI
$this->addFile('api/testApi.php');
$this->addFile('api/testAuto.php');
$this->addFile('api/testSavedSearches.php');
$this->addFile('api/testAcl.php');
$this->addFile('api/testAuthentication.php');
$this->addFile('api/testDocument.php');
$this->addFile('api/testFolder.php');
$this->addFile('api/testBulkActions.php');
$this->addFile('api/testCollection.php');
// $this->addFile('SQLFile/test_sqlfile.php');
// $this->addFile('cache/testCache.php');
// $this->addFile('config/testConfig.php');
// $this->addFile('document/testDocument.php');
// $this->addFile('document/testDocumentUtil.php');
// $this->addFile('folder/testFolder.php');
// $this->addFile('browseutil/testBrowseUtil.php');
// $this->addFile('filelike/testStringFileLike.php');
// Search (2) and indexing
$this->addFile('documentProcessor/testExtracters.php');
$this->addFile('documentProcessor/testGuidInserter.php');
$this->addFile('search2/testSearch.php');
}
}
$test = &new UnitTests();
if (SimpleReporter::inCli()) {
exit ($test->run(new KTTextReporter()) ? 0 : 1);
}
// pass parameter ?show=all to display all passes
$param = (isset($_REQUEST['show']) && $_REQUEST['show'] == 'all') ? true : false;
$test->run(new KTHtmlReporter($param));
?>