From a1bec12b2e3b0fdfb1a575d312af77551b0b48eb Mon Sep 17 00:00:00 2001 From: Imran Sobir Date: Thu, 9 Mar 2017 22:07:55 +0500 Subject: [PATCH] Ensure qute:javascript throws QuteSchemeOSError on 404. --- tests/unit/browser/test_qutescheme.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/unit/browser/test_qutescheme.py b/tests/unit/browser/test_qutescheme.py index 0f2504e09..c8e4eac4e 100644 --- a/tests/unit/browser/test_qutescheme.py +++ b/tests/unit/browser/test_qutescheme.py @@ -58,11 +58,11 @@ class TestJavascriptHandler: assert data == content - def test_qutejavascript_error(self): + def test_qutejavascript_404(self): url = QUrl("qute://javascript/404.js") - with pytest.raises(OSError): - qutescheme.qute_javascript(url) + with pytest.raises(qutescheme.QuteSchemeOSError): + qutescheme.data_for_url(url) def test_qutejavascript_empty_query(self): url = QUrl("qute://javascript")