summaryrefslogtreecommitdiff
path: root/core/tests
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2008-11-05 09:42:47 +0000
committerBharat Mediratta <bharat@menalto.com>2008-11-05 09:42:47 +0000
commitae00f739445717885e2fc82e241bae38b7e58d44 (patch)
tree96feb40e2ffbaa61a46500288d3e7a8fe831d155 /core/tests
parente35c154414ac73788645666b3e4e71722706c6cd (diff)
* Add thumbnail and resize dimensions to the item table and use them
properly in the theme. * Move thumbnail and resize generation down into the model for consistency. * Add a sample thumbnail for albums * Fix a bug in the ORM to clear the cache when we reload an object. * Add Kohana docs to the scaffold.
Diffstat (limited to 'core/tests')
-rw-r--r--core/tests/Photo_Test.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/core/tests/Photo_Test.php b/core/tests/Photo_Test.php
index 0980a187..cc4921c0 100644
--- a/core/tests/Photo_Test.php
+++ b/core/tests/Photo_Test.php
@@ -63,7 +63,9 @@ class Photo_Test extends Unit_Test_Case {
public function resize_url_test() {
$rand = rand();
- $photo = photo::create(1, DOCROOT . "core/tests/test.jpg", "$rand.jpg", $rand, $rand);
- $this->assert_equal("http://./var/resizes/{$rand}.resize.jpg", $photo->resize_url());
+ $album = album::create(1, $rand, $rand, $rand);
+ $photo = photo::create($album->id, DOCROOT . "core/tests/test.jpg", "$rand.jpg", $rand, $rand);
+
+ $this->assert_equal("http://./var/resizes/{$rand}/{$rand}.resize.jpg", $photo->resize_url());
}
}