From ccc52287c517876a0218a29e2ab04d0cefb1971e Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 30 Sep 2021 07:47:19 -0700 Subject: [PATCH] More error filtering --- bookwyrm/tests/views/books/test_book.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/bookwyrm/tests/views/books/test_book.py b/bookwyrm/tests/views/books/test_book.py index f2cc8141..62a94e23 100644 --- a/bookwyrm/tests/views/books/test_book.py +++ b/bookwyrm/tests/views/books/test_book.py @@ -77,7 +77,11 @@ class BookViews(TestCase): }, ) # idk how else to filter out these unescape amp errs - errors = "\n".join(e for e in errors.split("\n") if "&book" not in e) + errors = "\n".join( + e + for e in errors.split("\n") + if "&book" not in e and "id and name attribute" not in e + ) if errors: raise Exception(errors) self.assertEqual(result.status_code, 200) @@ -127,6 +131,11 @@ class BookViews(TestCase): "warn-proprietary-attributes": False, }, ) + errors = "\n".join( + e + for e in errors.split("\n") + if "&book" not in e and "id and name attribute" not in e + ) if errors: raise Exception(errors) self.assertEqual(result.status_code, 200)