Skip to content

Commit 282258d

Browse files
committed
feat: assert that the root DiffNode is unchanged
1 parent da90378 commit 282258d

File tree

1 file changed

+4
-0
lines changed
  • src/main/java/org/variantsync/diffdetective/variation/diff

1 file changed

+4
-0
lines changed

src/main/java/org/variantsync/diffdetective/variation/diff/DiffNode.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -763,6 +763,10 @@ public void assertConsistency() {
763763
if (pb != null && pa == null) {
764764
Assert.assertTrue(isRem());
765765
}
766+
// the root was not edited
767+
if (pb == null && pa == null) {
768+
Assert.assertTrue(isNon());
769+
}
766770
// a node with exactly two parents was not edited
767771
if (pb != null && pa != null) {
768772
Assert.assertTrue(isNon());

0 commit comments

Comments
 (0)