X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/6d42bc478e3d1bd90eb294464748c21e4de0fc63..6d7faa17f8ba5a94528372f246b2e774dc533a10:/src/dictionary/tests.py diff --git a/src/dictionary/tests.py b/src/dictionary/tests.py old mode 100755 new mode 100644 index 0b5924bb0..ae92530e4 --- a/src/dictionary/tests.py +++ b/src/dictionary/tests.py @@ -1,9 +1,10 @@ -# This file is part of Wolnelektury, licensed under GNU Affero GPLv3 or later. -# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information. +# This file is part of Wolne Lektury, licensed under GNU Affero GPLv3 or later. +# Copyright © Fundacja Wolne Lektury. See NOTICE for more information. # from django.core.files.base import ContentFile from catalogue.test_utils import * from catalogue.models import Book +from django.contrib.auth.models import User class DictionaryTests(WLTestCase): @@ -17,6 +18,9 @@ class DictionaryTests(WLTestCase): epoch="X-Epoch", **info_args("Default Book") ) + self.user = User.objects.create(username='test') + self.user.set_password('test') + self.user.save() def test_book_with_footnote(self): book_text = b""" @@ -28,6 +32,7 @@ class DictionaryTests(WLTestCase): """ book = Book.from_text_and_meta(ContentFile(book_text), self.book_info) + self.client.login(username='test', password='test') self.assertEqual( len(self.client.get('/przypisy/').context['object_list']),