Extend tests
This commit is contained in:
@@ -251,13 +251,17 @@ def testCoreIndexData_IndexHeading():
|
|||||||
"note.consitency": "Only explode once",
|
"note.consitency": "Only explode once",
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Append Synopsis
|
||||||
|
head.setComment(nwComment.SYNOPSIS.name, "", "How it started ...")
|
||||||
|
assert head.synopsis == "In the beginning ...\n\nHow it started ..."
|
||||||
|
|
||||||
# Unpack KeyError
|
# Unpack KeyError
|
||||||
with pytest.raises(KeyError, match="Unknown key in heading entry"):
|
with pytest.raises(KeyError, match="Unknown key in heading entry"):
|
||||||
head.unpackData({"stuff": "more stuff"})
|
head.unpackData({"stuff": "more stuff"})
|
||||||
|
|
||||||
# Unpack Comments
|
# Unpack Comments
|
||||||
head.unpackData({"summary": "How it started ..."})
|
head.unpackData({"summary": "How it started ..."})
|
||||||
assert head.synopsis == "How it started ..."
|
assert head.synopsis == "How it started ..." # This resets the comments dictionary
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.core
|
@pytest.mark.core
|
||||||
|
|||||||
Reference in New Issue
Block a user