example add code

This commit is contained in:
Antonis Geralis 2022-09-14 14:59:04 +03:00
parent 17d40e628a
commit 6d750ded81
1 changed files with 6 additions and 0 deletions

View File

@ -99,6 +99,12 @@ when defined(runFuzzTests) and isMainModule:
x.nodes[6].edges.len == 0 and
x.nodes[7].edges.len == 0:
doAssert false
# Here you could call library functions and check invariants.
# Such as when removing edges, the number of nodes remains the same.
#var x = x
#let oldLen = x.nodes.len
#x.deleteEdge(1, 2)
#doAssert oldLen == x.nodes.len
defaultMutator(fuzzTarget)