Really fix sorting numerically for resolutions. Added tests to check it.

This commit is contained in:
Colin Kuskie 2010-08-17 13:30:39 -07:00
parent 86a190e3c6
commit 67272517ce
2 changed files with 14 additions and 2 deletions

View file

@ -49,7 +49,7 @@ $album
#----------------------------------------------------------------------------
# Tests
plan tests => 13;
plan tests => 14;
#----------------------------------------------------------------------------
# makeResolutions gets default resolutions from a parent Photo Gallery asset
@ -80,6 +80,12 @@ cmp_deeply(
"makeResolutions makes all the required resolutions with the appropriate names.",
);
cmp_deeply(
$photo->getResolutions,
[qw/640.jpg 800.jpg 1024.jpg 1600.jpg/],
'getResolutions: sorts numerically'
);
TODO: {
local $TODO = 'Test to ensure the files are created with correct resolution and density';
}