c.gallery_start = 3
c.save()
- print "gallery starts:",self.book2[0].gallery_start, self.book2[1].gallery_start
-
self.make_gallery(self.book1, {
'1-0001_1l' : 'aa',
'1-0001_2r' : 'bb',
files = listdir(join(self.scandir, self.book1.gallery))
files.sort()
- print files
self.assertEqual(files, [
'1-0001_1l',
'1-0001_2r',
files = listdir(join(self.scandir, self.book1.gallery))
files.sort()
- print files
self.assertEqual(files, [
'0-0001_1l',
'0-0001_2r',
def test_none_indexed(self):
- import nose.tools
self.book2 = Book.create(self.user, 'book 2', slug='book2')
self.make_gallery(self.book1, {
'1-0001_1l' : 'aa',
files = listdir(join(self.scandir, self.book1.gallery))
files.sort()
- print files
self.assertEqual(files, [
'0-1-0001_1l',
'0-1-0001_2r',