--------------------------------------------------------------------------- Property: sameTree is reflexive and symmetric --------------------------------------------------------------------------- reqproof:proptest sameTree Verifies: SYS-REQ-009 [property]
(t *testing.T)
| 801 | // reqproof:proptest sameTree |
| 802 | // Verifies: SYS-REQ-009 [property] |
| 803 | func TestPropertySameTreeEquivalence(t *testing.T) { |
| 804 | // Reflexive: sameTree(p,p) is true for any non-empty path. |
| 805 | reflexive := func(p []string) bool { |
| 806 | if len(p) == 0 { |
| 807 | return true |
| 808 | } |
| 809 | return sameTree(p, p) |
| 810 | } |
| 811 | if err := quick.Check(reflexive, &quick.Config{MaxCount: 2000}); err != nil { |
| 812 | t.Fatalf("sameTree not reflexive: %v", err) |
| 813 | } |
| 814 | } |
| 815 | |
| 816 | // --------------------------------------------------------------------------- |
| 817 | // Property: internalGet agrees with Get (Get is a thin projection) |
nothing calls this directly
no test coverage detected