aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@archive.org>2021-11-03 19:42:49 -0700
committerBryan Newbold <bnewbold@archive.org>2021-11-03 19:42:49 -0700
commit8c7fcc943bc217bf456362b9e205910623974fd0 (patch)
tree065fc21894d650e0cb7abe85cdeb633acc031527
parent7439ade08f185eaa6ac44b8ab509a8d3c047d574 (diff)
downloadgrobid_tei_xml-8c7fcc943bc217bf456362b9e205910623974fd0.tar.gz
grobid_tei_xml-8c7fcc943bc217bf456362b9e205910623974fd0.zip
move test files into sub-directories
-rw-r--r--tests/files/citation/emdash.tei.xml (renamed from tests/files/citation_emdash.tei.xml)0
-rw-r--r--tests/files/citation/empty.tei.xml (renamed from tests/files/empty_citation.tei.xml)0
-rw-r--r--tests/files/citation/empty_unstructured.tei.xml (renamed from tests/files/empty_citation_unstructured.tei.xml)0
-rw-r--r--tests/files/citation_list/emdash.tei.xml (renamed from tests/files/citation_list_emdash.tei.xml)0
-rw-r--r--tests/files/citation_list/example.tei.xml (renamed from tests/files/example_citation_list.xml)0
-rw-r--r--tests/files/citation_list/note.tei.xml (renamed from tests/files/citation_note.xml)0
-rw-r--r--tests/files/document/23b29ea36382680716be08fc71aa81bd226e8a85.tei.xml (renamed from tests/files/23b29ea36382680716be08fc71aa81bd226e8a85.xml)0
-rw-r--r--tests/files/document/example.tei.xml (renamed from tests/files/example_grobid.tei.xml)0
-rw-r--r--tests/files/document/plos.tei.xml (renamed from tests/files/example_grobid_plos.tei.xml)0
-rw-r--r--tests/test_parse.py18
10 files changed, 9 insertions, 9 deletions
diff --git a/tests/files/citation_emdash.tei.xml b/tests/files/citation/emdash.tei.xml
index 846085c..846085c 100644
--- a/tests/files/citation_emdash.tei.xml
+++ b/tests/files/citation/emdash.tei.xml
diff --git a/tests/files/empty_citation.tei.xml b/tests/files/citation/empty.tei.xml
index cb21f6e..cb21f6e 100644
--- a/tests/files/empty_citation.tei.xml
+++ b/tests/files/citation/empty.tei.xml
diff --git a/tests/files/empty_citation_unstructured.tei.xml b/tests/files/citation/empty_unstructured.tei.xml
index 35aee19..35aee19 100644
--- a/tests/files/empty_citation_unstructured.tei.xml
+++ b/tests/files/citation/empty_unstructured.tei.xml
diff --git a/tests/files/citation_list_emdash.tei.xml b/tests/files/citation_list/emdash.tei.xml
index b47f85b..b47f85b 100644
--- a/tests/files/citation_list_emdash.tei.xml
+++ b/tests/files/citation_list/emdash.tei.xml
diff --git a/tests/files/example_citation_list.xml b/tests/files/citation_list/example.tei.xml
index 218fa46..218fa46 100644
--- a/tests/files/example_citation_list.xml
+++ b/tests/files/citation_list/example.tei.xml
diff --git a/tests/files/citation_note.xml b/tests/files/citation_list/note.tei.xml
index 55fe81c..55fe81c 100644
--- a/tests/files/citation_note.xml
+++ b/tests/files/citation_list/note.tei.xml
diff --git a/tests/files/23b29ea36382680716be08fc71aa81bd226e8a85.xml b/tests/files/document/23b29ea36382680716be08fc71aa81bd226e8a85.tei.xml
index dbc8be5..dbc8be5 100644
--- a/tests/files/23b29ea36382680716be08fc71aa81bd226e8a85.xml
+++ b/tests/files/document/23b29ea36382680716be08fc71aa81bd226e8a85.tei.xml
diff --git a/tests/files/example_grobid.tei.xml b/tests/files/document/example.tei.xml
index 5726877..5726877 100644
--- a/tests/files/example_grobid.tei.xml
+++ b/tests/files/document/example.tei.xml
diff --git a/tests/files/example_grobid_plos.tei.xml b/tests/files/document/plos.tei.xml
index fe6a05a..fe6a05a 100644
--- a/tests/files/example_grobid_plos.tei.xml
+++ b/tests/files/document/plos.tei.xml
diff --git a/tests/test_parse.py b/tests/test_parse.py
index 832ee78..32d7ea9 100644
--- a/tests/test_parse.py
+++ b/tests/test_parse.py
@@ -130,7 +130,7 @@ def test_elementtree() -> None:
def test_example_grobid_tei_xml() -> None:
- with open("tests/files/example_grobid.tei.xml", "r") as f:
+ with open("tests/files/document/example.tei.xml", "r") as f:
blob = f.read()
doc = parse_document_xml(blob)
@@ -232,7 +232,7 @@ def test_single_citations_xml() -> None:
def test_citation_list_xml() -> None:
- with open("tests/files/example_citation_list.xml", "r") as f:
+ with open("tests/files/citation_list/example.tei.xml", "r") as f:
tei_xml = f.read()
citations = parse_citation_list_xml(tei_xml)
@@ -276,7 +276,7 @@ def test_citation_list_xml() -> None:
def test_grobid_070_document() -> None:
# more recent GROBID v0.7.0 output
- with open("tests/files/example_grobid_plos.tei.xml", "r") as f:
+ with open("tests/files/document/plos.tei.xml", "r") as f:
tei_xml = f.read()
doc = parse_document_xml(tei_xml)
@@ -320,10 +320,10 @@ def test_grobid_070_document() -> None:
def test_empty_citations() -> None:
- with open("tests/files/empty_citation_unstructured.tei.xml", "r") as f:
+ with open("tests/files/citation/empty_unstructured.tei.xml", "r") as f:
mostly_empty_xml = f.read()
- with open("tests/files/empty_citation.tei.xml", "r") as f:
+ with open("tests/files/citation/empty.tei.xml", "r") as f:
empty_xml = f.read()
assert parse_citation_xml(empty_xml) is None
@@ -342,9 +342,9 @@ def test_empty_citations() -> None:
def test_citation_emdash() -> None:
- with open("tests/files/citation_emdash.tei.xml", "rb") as f:
+ with open("tests/files/citation/emdash.tei.xml", "rb") as f:
tei_xml_bytes = f.read()
- with open("tests/files/citation_emdash.tei.xml", "r") as f2:
+ with open("tests/files/citation/emdash.tei.xml", "r") as f2:
tei_xml_str = f2.read()
# that dash is a unicode emdash
@@ -367,9 +367,9 @@ def test_citation_emdash() -> None:
def test_citation_list_utf8() -> None:
- with open("tests/files/citation_list_emdash.tei.xml", "rb") as f:
+ with open("tests/files/citation_list/emdash.tei.xml", "rb") as f:
tei_xml_bytes = f.read()
- with open("tests/files/citation_list_emdash.tei.xml", "r") as f2:
+ with open("tests/files/citation_list/emdash.tei.xml", "r") as f2:
tei_xml_str = f2.read()
unstructured = "Goodman, N. (1972). A world of individuals. In Problems and projects (pp. 155–172). Bobs-Merrill company."