(t *testing.T)
| 537 | } |
| 538 | |
| 539 | func TestIncrementSimple(t *testing.T) { |
| 540 | bsi := setup() |
| 541 | bsi.IncrementAll() |
| 542 | for i := 0; i < int(bsi.MaxValue); i++ { |
| 543 | a, _ := bsi.GetValue(uint64(i)) |
| 544 | assert.Equal(t, int64(i+1), a) |
| 545 | } |
| 546 | bsi.Increment(BitmapOf(0)) |
| 547 | x, _ := bsi.GetValue(uint64(0)) |
| 548 | assert.Equal(t, int64(2), x) |
| 549 | for i := 1; i < int(bsi.MaxValue); i++ { |
| 550 | a, _ := bsi.GetValue(uint64(i)) |
| 551 | assert.Equal(t, int64(i+1), a) |
| 552 | } |
| 553 | } |
| 554 | |
| 555 | func TestIncrementFromZero(t *testing.T) { |
| 556 | bsi := NewDefaultBSI() |
nothing calls this directly
no test coverage detected
searching dependent graphs…