diff options
author | Bharat Mediratta <bharat@menalto.com> | 2008-12-08 10:46:06 +0000 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2008-12-08 10:46:06 +0000 |
commit | 85239ec75034fb9ad0f3c2d26d77d760a4e6dfd7 (patch) | |
tree | d0b816dfb6170dbd8075db176bbd7e3231d48e34 | |
parent | b0f39497b4ab4315cba1ba4db9633b34e72ec440 (diff) |
Ignore gallery_unit_test/views/kohana_*.php
-rw-r--r-- | core/tests/File_Structure_Test.php | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/core/tests/File_Structure_Test.php b/core/tests/File_Structure_Test.php index 861a764c..4fb58916 100644 --- a/core/tests/File_Structure_Test.php +++ b/core/tests/File_Structure_Test.php @@ -35,10 +35,6 @@ class File_Structure_Test extends Unit_Test_Case { $dir = new GalleryCodeFilterIterator( new RecursiveIteratorIterator(new RecursiveDirectoryIterator(DOCROOT))); foreach ($dir as $file) { - if ($file->getFilename() == 'kohana_unit_test.php') { - // Exception: this file must be named accordingly for the test framework - continue; - } if (strpos($file, "views")) { $this->assert_true( preg_match("#/views/.*?(\.html|mrss)\.php$#", @@ -120,15 +116,18 @@ class GalleryCodeFilterIterator extends FilterIterator { // Skip anything that we didn't write $path_name = $this->getInnerIterator()->getPathName(); $path_name = strtr($path_name, DIRECTORY_SEPARATOR, '/'); - return !(strpos($path_name, ".svn") || - substr($path_name, -1, 1) == "~" || - strpos($path_name, SYSPATH) !== false || - strpos($path_name, MODPATH . 'forge') !== false || - strpos($path_name, MODPATH . 'unit_test') !== false || - strpos($path_name, MODPATH . 'mptt') !== false || - strpos($path_name, MODPATH . 'kodoc') !== false || - strpos($path_name, MODPATH . 'user/libraries/PasswordHash') !== false || - strpos($path_name, DOCROOT . 'var') !== false || - strpos($path_name, DOCROOT . 'test') !== false); + return !( + strpos($path_name, ".svn") || + substr($path_name, -1, 1) == "~" || + strpos($path_name, DOCROOT . 'test') !== false || + strpos($path_name, DOCROOT . 'var') !== false || + strpos($path_name, MODPATH . 'forge') !== false || + strpos($path_name, MODPATH . 'kodoc') !== false || + strpos($path_name, MODPATH . 'mptt') !== false || + strpos($path_name, MODPATH . 'unit_test') !== false || + strpos($path_name, MODPATH . 'gallery_unit_test/views/kohana_error_page.php') !== false || + strpos($path_name, MODPATH . 'gallery_unit_test/views/kohana_unit_test.php') !== false || + strpos($path_name, MODPATH . 'user/libraries/PasswordHash') !== false || + strpos($path_name, SYSPATH) !== false); } } |