From 959274c730c6350bedaef9ecf395e4addc9d2b96 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Tue, 2 Jul 2013 17:08:37 -0400 Subject: [PATCH] Adapt the tests to the new way of making URLs. --- lms/djangoapps/staticbook/tests.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lms/djangoapps/staticbook/tests.py b/lms/djangoapps/staticbook/tests.py index 34574de639..92440656c7 100644 --- a/lms/djangoapps/staticbook/tests.py +++ b/lms/djangoapps/staticbook/tests.py @@ -120,14 +120,14 @@ class StaticPdfBookTest(StaticBookTest): course = self.make_course(pdf_textbooks=[PDF_BOOK]) # It's no longer possible to use a non-integer chapter. with self.assertRaises(NoReverseMatch): - reverse('pdf_book', kwargs={'course_id': course.id, 'book_index': 0, 'chapter': 'xyzzy'}) + self.make_url('pdf_book', book_index=0, chapter='xyzzy') def test_page_xss(self): # The page in the URL used to go right on the page. course = self.make_course(pdf_textbooks=[PDF_BOOK]) # It's no longer possible to use a non-integer page. with self.assertRaises(NoReverseMatch): - reverse('pdf_book', kwargs={'course_id': course.id, 'book_index': 0, 'page': 'xyzzy'}) + self.make_url('pdf_book', book_index=0, page='xyzzy') class StaticHtmlBookTest(StaticBookTest): @@ -170,4 +170,4 @@ class StaticHtmlBookTest(StaticBookTest): course = self.make_course(pdf_textbooks=[HTML_BOOK]) # It's no longer possible to use a non-integer chapter. with self.assertRaises(NoReverseMatch): - reverse('html_book', kwargs={'course_id': course.id, 'book_index': 0, 'chapter': 'xyzzy'}) + self.make_url('html_book', book_index=0, chapter='xyzzy')