diff --git a/drafts/v1.0/MetronInfo.xsd b/drafts/v1.0/MetronInfo.xsd
index f913ca7..4d45091 100644
--- a/drafts/v1.0/MetronInfo.xsd
+++ b/drafts/v1.0/MetronInfo.xsd
@@ -16,7 +16,7 @@
-
+
@@ -92,7 +92,7 @@
-
+
diff --git a/tests/test.py b/tests/test.py
index 8a39df7..9e06ebc 100644
--- a/tests/test.py
+++ b/tests/test.py
@@ -8,19 +8,45 @@
@pytest.mark.parametrize(
- ("xsd", "xml"), [(TEST_XSD, TEST_FILES_PATH / "valid.xml")], ids=["valid_xml"]
+ ("xsd", "xml"),
+ [
+ (TEST_XSD, TEST_FILES_PATH / "valid.xml"),
+ (
+ TEST_XSD,
+ ''
+ "Foo0",
+ ),
+ (
+ TEST_XSD,
+ ''
+ "Foo0",
+ ),
+ ],
+ ids=["valid_xml", "zero_page_count", "volume_zero"],
)
-def test_valid(xsd, xml) -> None:
+def test_valid(xsd: Path, xml: Path | str) -> None:
schema = XMLSchema11(xsd)
schema.validate(xml)
@pytest.mark.parametrize(
("xsd", "xml"),
- [(TEST_XSD, TEST_FILES_PATH / "dup_primary_attr.xml")],
- ids=["dup_primary_attr_xml"],
+ [
+ (TEST_XSD, TEST_FILES_PATH / "dup_primary_attr.xml"),
+ (
+ TEST_XSD,
+ ''
+ "Foo-1",
+ ),
+ (
+ TEST_XSD,
+ ''
+ "Foo-1",
+ ),
+ ],
+ ids=["dup_primary_attr_xml", "negative_page_count", "negative_volume"],
)
-def test_invalid(xsd, xml) -> None:
+def test_invalid(xsd: Path, xml: Path | str) -> None:
schema = XMLSchema11(xsd)
with pytest.raises(XMLSchemaValidationError):
schema.validate(xml)