summaryrefslogtreecommitdiff
path: root/core/tests
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-01-19 07:26:25 +0000
committerBharat Mediratta <bharat@menalto.com>2009-01-19 07:26:25 +0000
commitfc8cf562f5d7d4f0514512703f017f2979a6dea6 (patch)
treef447eedc4245b5e00252e0bef0eec2e53dcd22c9 /core/tests
parent5e94456ce99aef158d8c35b738bb7fb7d29c6e5b (diff)
Fix up various little things to get File_Structure_Test to pass.
Diffstat (limited to 'core/tests')
-rw-r--r--core/tests/File_Structure_Test.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/core/tests/File_Structure_Test.php b/core/tests/File_Structure_Test.php
index 2c6bd239..e648192a 100644
--- a/core/tests/File_Structure_Test.php
+++ b/core/tests/File_Structure_Test.php
@@ -60,7 +60,9 @@ class File_Structure_Test extends Unit_Test_Case {
$expected = $this->_get_preamble(__FILE__);
foreach ($dir as $file) {
- if (preg_match("/views/", $file->getPathname())) {
+ if (preg_match("/views/", $file->getPathname()) ||
+ $file->getPathName() == DOCROOT . "installer/database_config.php" ||
+ $file->getPathName() == DOCROOT . "installer/init_var.php") {
// The preamble for views is a single line that prevents direct script access
$lines = file($file->getPathname());
$this->assert_equal(
@@ -70,8 +72,8 @@ class File_Structure_Test extends Unit_Test_Case {
} else if (preg_match("|\.php$|", $file->getPathname())) {
$actual = $this->_get_preamble($file->getPathname());
if ($file->getPathName() == DOCROOT . "index.php" ||
- $file->getPathName() == DOCROOT . "installer/install.php") {
- // index.php and installer.php allow direct access, so modify our expectations for them
+ $file->getPathName() == DOCROOT . "installer/index.php") {
+ // index.php and installer/index.php allow direct access; modify our expectations for them
$index_expected = $expected;
$index_expected[0] = "<?php";
$this->assert_equal($index_expected, $actual, "in file: {$file->getPathname()}");