test_files.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. if (!defined('HTMLPurifierTest')) exit;
  3. // These arrays are defined by this file and can be relied upon.
  4. $test_files = array();
  5. $test_dirs = array();
  6. $test_dirs_exclude = array();
  7. $vtest_dirs = array();
  8. $htmlt_dirs = array();
  9. $phpt_dirs = array();
  10. $break = true;
  11. switch ($AC['type']) {
  12. case '':
  13. $break = false;
  14. case 'htmlpurifier':
  15. $test_dirs[] = 'HTMLPurifier';
  16. $test_files[] = 'HTMLPurifierTest.php';
  17. $test_dirs_exclude['HTMLPurifier/Filter/ExtractStyleBlocksTest.php'] = true;
  18. $test_files[] = 'HTMLPurifier/Filter/ExtractStyleBlocksTest.php';
  19. if ($break) break;
  20. case 'configdoc':
  21. if (version_compare(PHP_VERSION, '5.2', '>=')) {
  22. // $test_dirs[] = 'ConfigDoc'; // no test files currently!
  23. }
  24. if ($break) break;
  25. case 'fstools':
  26. $test_dirs[] = 'FSTools';
  27. if ($break) break;
  28. case 'htmlt':
  29. $htmlt_dirs[] = 'HTMLPurifier/HTMLT';
  30. if ($break) break;
  31. case 'vtest':
  32. $vtest_dirs[] = 'HTMLPurifier/ConfigSchema/Validator';
  33. if ($break) break;
  34. case 'phpt':
  35. if (!$AC['disable-phpt'] && version_compare(PHP_VERSION, '5.2', '>=')) {
  36. $phpt_dirs[] = 'HTMLPurifier/PHPT';
  37. }
  38. }
  39. // vim: et sw=4 sts=4