diff options
Diffstat (limited to 'mapreduce/tests')
| -rw-r--r-- | mapreduce/tests/test_grobid2json.py | 14 | 
1 files changed, 14 insertions, 0 deletions
| diff --git a/mapreduce/tests/test_grobid2json.py b/mapreduce/tests/test_grobid2json.py new file mode 100644 index 0000000..40853dd --- /dev/null +++ b/mapreduce/tests/test_grobid2json.py @@ -0,0 +1,14 @@ + +import json +import pytest +from grobid2json import * + + +def test_small_xml(): +     +    with open('tests/files/small.xml', 'r') as f: +        tei_xml = f.read() +    with open('tests/files/small.json', 'r') as f: +        json_form  = json.loads(f.read()) + +    assert teixml2json(tei_xml) == json_form | 
