X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/4298f7948e8963176debf5877fce30c49ae4e3ad..c0a7799619e217e2eac724b1a688ad37f0182253:/src/catalogue/tests/test_visit.py diff --git a/src/catalogue/tests/test_visit.py b/src/catalogue/tests/test_visit.py index 5e640adad..c170c00b4 100644 --- a/src/catalogue/tests/test_visit.py +++ b/src/catalogue/tests/test_visit.py @@ -13,14 +13,14 @@ class VisitTest(WLTestCase): def setUp(self): WLTestCase.setUp(self) author = PersonStub(("Jane",), "Doe") - book_info = BookInfoStub(author=author, genre="Genre", + book_info = BookInfoStub(author=author, genre="Sielanka", epoch='Epoch', kind="Kind", **info_args(u"A book")) self.book = models.Book.from_text_and_meta(ContentFile(''' - Theme + Sielanka Test @@ -40,11 +40,13 @@ class VisitTest(WLTestCase): 'nowe/', 'lektura/a-book/', 'lektura/a-book.html', - 'lektura/a-book/motyw/theme/', - 'motyw/theme/', + 'lektura/a-book/motyw/sielanka/', + 'motyw/sielanka/', + 'sielanka/', 'autor/jane-doe/', + 'daisy/', # 'autor/jane-doe/gatunek/genre/', - # 'autor/jane-doe/gatunek/genre/motyw/theme/', + # 'autor/jane-doe/gatunek/genre/motyw/sielanka/', 'b/%d/mini.pl.html' % self.book.pk, 'b/%d/mini_nolink.pl.html' % self.book.pk, 'b/%d/short.pl.html' % self.book.pk, @@ -56,7 +58,7 @@ class VisitTest(WLTestCase): 'lektury/nonexistent/', # Nonexistent Collection. 'lektura/nonexistent/', # Nonexistent Book. 'lektura/nonexistent.html', # Nonexistent Book's HTML. - 'lektura/nonexistent/motyw/theme/', # Nonexistent Book's theme. + 'lektura/nonexistent/motyw/sielanka/', # Nonexistent Book's theme. 'lektura/a-book/motyw/nonexistent/', # Nonexistent theme in a Book. 'autor/nonexistent/', # Nonexistent author. 'motyw/nonexistent/', # Nonexistent theme. @@ -72,7 +74,6 @@ class VisitTest(WLTestCase): prefix = '/katalog/' for expected_status, urls in url_map.items(): for url in urls: - print(url) status = self.client.get(prefix + url).status_code self.assertEqual( status, expected_status,