diff --git a/marc_tools/tests/test_marc_extractor.py b/marc_tools/tests/test_marc_extractor.py index 20a2c4917bfc465c05312901cd3718dd5f33b76d..700ab5841d5118b4448295f7ce0969ed453efce6 100644 --- a/marc_tools/tests/test_marc_extractor.py +++ b/marc_tools/tests/test_marc_extractor.py @@ -1,5 +1,5 @@ import pytest -import marc_extractor +import marc_tools.marc_extractor as marc_extractor class TestConstructSingleCommand: diff --git a/sru/tests/error.xml b/sru/tests/error.xml new file mode 100644 index 0000000000000000000000000000000000000000..b86a99a71ef86dc0ebf887b3f46b3a757a51081a --- /dev/null +++ b/sru/tests/error.xml @@ -0,0 +1,9 @@ + + 1.2 + + + 200801 + Catalog search has encountered an error + + + \ No newline at end of file diff --git a/sru/tests/test_almasru.py b/sru/tests/test_almasru.py new file mode 100644 index 0000000000000000000000000000000000000000..63b7dd9e56cc5c4cc677b3147926a71620bbd5c0 --- /dev/null +++ b/sru/tests/test_almasru.py @@ -0,0 +1,12 @@ +import pytest +import sru.almasru as almasru + +retriever = almasru.RecordRetriever('obv-at-oenb', '43ACC_ONB', 'marcxml') + + +class TestRecordRetriever: + + def test_erroneous_xml(self): + with pytest.raises(almasru.SruException): + retriever.by_mms_id('MMS-ID') +