From 534b8525ce95f9d11875cde7a31c93d9c0557475 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Thu, 28 May 2009 01:55:42 -0700 Subject: Rename Core_Installer_Test -> Gallery_Installer_Test to match the change from application -> modules/gallery. --- modules/gallery/tests/Core_Installer_Test.php | 50 ------------------------ modules/gallery/tests/Gallery_Installer_Test.php | 50 ++++++++++++++++++++++++ 2 files changed, 50 insertions(+), 50 deletions(-) delete mode 100644 modules/gallery/tests/Core_Installer_Test.php create mode 100644 modules/gallery/tests/Gallery_Installer_Test.php diff --git a/modules/gallery/tests/Core_Installer_Test.php b/modules/gallery/tests/Core_Installer_Test.php deleted file mode 100644 index 24d24b38..00000000 --- a/modules/gallery/tests/Core_Installer_Test.php +++ /dev/null @@ -1,50 +0,0 @@ -assert_true(file_exists(VARPATH . "albums")); - $this->assert_true(file_exists(VARPATH . "resizes")); - } - - public function install_registers_gallery_module_test() { - $gallery = ORM::factory("module")->where("name", "gallery")->find(); - $this->assert_equal("gallery", $gallery->name); - - // This is probably too volatile to keep for long - $this->assert_equal(1, $gallery->version); - } - - public function install_creates_root_item_test() { - $max_right = ORM::factory("item") - ->select("MAX(`right`) AS `right`") - ->find()->right; - $root = ORM::factory('item')->find(1); - $this->assert_equal("Gallery", $root->title); - $this->assert_equal(1, $root->left); - $this->assert_equal($max_right, $root->right); - $this->assert_equal(null, $root->parent_id); - $this->assert_equal(1, $root->level); - } -} diff --git a/modules/gallery/tests/Gallery_Installer_Test.php b/modules/gallery/tests/Gallery_Installer_Test.php new file mode 100644 index 00000000..24d24b38 --- /dev/null +++ b/modules/gallery/tests/Gallery_Installer_Test.php @@ -0,0 +1,50 @@ +assert_true(file_exists(VARPATH . "albums")); + $this->assert_true(file_exists(VARPATH . "resizes")); + } + + public function install_registers_gallery_module_test() { + $gallery = ORM::factory("module")->where("name", "gallery")->find(); + $this->assert_equal("gallery", $gallery->name); + + // This is probably too volatile to keep for long + $this->assert_equal(1, $gallery->version); + } + + public function install_creates_root_item_test() { + $max_right = ORM::factory("item") + ->select("MAX(`right`) AS `right`") + ->find()->right; + $root = ORM::factory('item')->find(1); + $this->assert_equal("Gallery", $root->title); + $this->assert_equal(1, $root->left); + $this->assert_equal($max_right, $root->right); + $this->assert_equal(null, $root->parent_id); + $this->assert_equal(1, $root->level); + } +} -- cgit v1.2.3