ILIAS  Release_4_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilGlobalSuite.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
15 {
16  public static function suite()
17  {
18  $suite = new ilGlobalSuite();
19 
20  echo "\n";
21 
22  // scan Modules and Services directories
23  $basedirs = array("Services", "Modules");
24 
25  foreach ($basedirs as $basedir)
26  {
27  // read current directory
28  $dir = opendir($basedir);
29 
30  while($file = readdir($dir))
31  {
32  if ($file != "." && $file != ".." && is_dir($basedir."/".$file))
33  {
34  $suite_path =
35  $basedir."/".$file."/test/il".$basedir.$file."Suite.php";
36  if (is_file($suite_path))
37  {
38  include_once($suite_path);
39 
40  $name = "il".$basedir.$file."Suite";
41  $s = new $name();
42  echo "Adding Suite: ".$name."\n";
43  $suite->addTest($s->suite());
44  //$suite->addTestSuite("ilSettingTest");
45  }
46  }
47  }
48  }
49  echo "\n";
50 
51  return $suite;
52  }
53 }
54 ?>