(c container, s []uint16)
| 16 | } |
| 17 | |
| 18 | func checkContent(c container, s []uint16) bool { |
| 19 | si := c.getShortIterator() |
| 20 | ctr := 0 |
| 21 | fail := false |
| 22 | for si.hasNext() { |
| 23 | if ctr == len(s) { |
| 24 | log.Println("HERE") |
| 25 | fail = true |
| 26 | break |
| 27 | } |
| 28 | i := si.next() |
| 29 | if i != s[ctr] { |
| 30 | |
| 31 | log.Println("THERE", i, s[ctr]) |
| 32 | fail = true |
| 33 | break |
| 34 | } |
| 35 | ctr++ |
| 36 | } |
| 37 | if ctr != len(s) { |
| 38 | log.Println("LAST") |
| 39 | fail = true |
| 40 | } |
| 41 | if fail { |
| 42 | log.Println("fail, found ") |
| 43 | si = c.getShortIterator() |
| 44 | z := 0 |
| 45 | for si.hasNext() { |
| 46 | si.next() |
| 47 | z++ |
| 48 | } |
| 49 | log.Println(z, len(s)) |
| 50 | } |
| 51 | |
| 52 | return !fail |
| 53 | } |
| 54 | |
| 55 | func testContainerIteratorPeekNext(t *testing.T, c container) { |
| 56 | testSize := 5000 |
no test coverage detected
searching dependent graphs…