aboutsummaryrefslogtreecommitdiffstats
path: root/tests/test_scrub.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_scrub.py')
-rw-r--r--tests/test_scrub.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/test_scrub.py b/tests/test_scrub.py
new file mode 100644
index 0000000..6c357ae
--- /dev/null
+++ b/tests/test_scrub.py
@@ -0,0 +1,15 @@
+
+import pytest
+
+from fatcat_scholar.schema import *
+
+
+def test_scrub():
+ vectors = [
+ ('“Please clean this piece… of text</b>„', '"Please clean this piece... of text"'),
+ ("<jats:p>blah", "blah"),
+ ]
+
+ for raw, fixed in vectors:
+ assert fixed == scrub_text(raw)
+