|
1 | 1 | import datetime |
2 | 2 |
|
3 | 3 | from tests.tests_tibiapy import TestCommons |
4 | | -from tibiapy import InvalidContent |
| 4 | +from tibiapy import InvalidContentError |
5 | 5 | from tibiapy.enums import ThreadStatus |
6 | 6 | from tibiapy.models import BoardEntry, CMPostArchive, ForumPost, LastPost, ThreadEntry |
7 | 7 | from tibiapy.parsers import (CMPostArchiveParser, ForumAnnouncementParser, ForumBoardParser, ForumSectionParser, |
@@ -81,7 +81,7 @@ def test_forum_section_parser_from_content_empty_section(self): |
81 | 81 | def test_forum_section_parser_from_content_unrelated_section(self): |
82 | 82 | content = self.load_resource(self.FILE_UNRELATED_SECTION) |
83 | 83 |
|
84 | | - with self.assertRaises(InvalidContent): |
| 84 | + with self.assertRaises(InvalidContentError): |
85 | 85 | ForumSectionParser.from_content(content) |
86 | 86 |
|
87 | 87 | # endregion |
@@ -128,7 +128,7 @@ def test_forum_board_parser_from_content_empty_threads(self): |
128 | 128 | def test_forum_board_parser_from_content_unrelated_section(self): |
129 | 129 | content = self.load_resource(self.FILE_UNRELATED_SECTION) |
130 | 130 |
|
131 | | - with self.assertRaises(InvalidContent): |
| 131 | + with self.assertRaises(InvalidContentError): |
132 | 132 | ForumBoardParser.from_content(content) |
133 | 133 |
|
134 | 134 | def test_forum_board_parser_from_content_invalid_page(self): |
@@ -246,7 +246,7 @@ def test_forum_announcement_from_content_not_found(self): |
246 | 246 | def test_forum_announcement_from_content_unrelated_section(self): |
247 | 247 | content = self.load_resource(self.FILE_UNRELATED_SECTION) |
248 | 248 |
|
249 | | - with self.assertRaises(InvalidContent): |
| 249 | + with self.assertRaises(InvalidContentError): |
250 | 250 | ForumAnnouncementParser.from_content(content, 34) |
251 | 251 |
|
252 | 252 | # endregion |
@@ -368,7 +368,7 @@ def test_forum_thread_parser_from_content_not_found(self): |
368 | 368 | def test_forum_thread_parser_from_content_unrelated_section(self): |
369 | 369 | content = self.load_resource(self.FILE_UNRELATED_SECTION) |
370 | 370 |
|
371 | | - with self.assertRaises(InvalidContent): |
| 371 | + with self.assertRaises(InvalidContentError): |
372 | 372 | ForumThreadParser.from_content(content) |
373 | 373 |
|
374 | 374 | # endregion |
@@ -423,7 +423,7 @@ def test_cm_post_archive_from_content_pages(self): |
423 | 423 |
|
424 | 424 | def test_cm_post_archive_from_content_unrelated_section(self): |
425 | 425 | content = self.load_resource(self.FILE_UNRELATED_SECTION) |
426 | | - with self.assertRaises(InvalidContent): |
| 426 | + with self.assertRaises(InvalidContentError): |
427 | 427 | CMPostArchiveParser.from_content(content) |
428 | 428 |
|
429 | 429 | def test_cm_post_archive_get_page_url_negative_page(self): |
|
0 commit comments