(b *testing.B)
| 224 | } |
| 225 | |
| 226 | func BenchmarkOnearrRev(b *testing.B) { |
| 227 | for api, testsize := range testSizes { |
| 228 | b.Run(testsize.Name, func(b *testing.B) { |
| 229 | verify := verifyIndex[api] |
| 230 | ap := testsize.AP |
| 231 | b.SetBytes(int64(ap.TotalSize())) |
| 232 | for i := 0; i < b.N; i++ { |
| 233 | it := onearrrev.NewIterator(ap) |
| 234 | total := 0 |
| 235 | for index, err := it.Next(); err == nil; index, err = it.Next() { |
| 236 | total += verify[index] * index |
| 237 | } |
| 238 | _ = total |
| 239 | } |
| 240 | }) |
| 241 | } |
| 242 | } |
| 243 | |
| 244 | func TestOnearrRevAdvance(t *testing.T) { |
| 245 | testIterator(t, func(ap *shape.AP) Iterator { return onearrrevadvance.NewIterator(ap) }) |
nothing calls this directly
no test coverage detected