(DocSet d1, DocSet d2)
| 157 | } |
| 158 | |
| 159 | public void iter(DocSet d1, DocSet d2) { |
| 160 | |
| 161 | DocIterator i1 = d1.iterator(); |
| 162 | DocIterator i2 = d2.iterator(); |
| 163 | |
| 164 | assertEquals(i1.hasNext(), i2.hasNext()); |
| 165 | |
| 166 | for (; ; ) { |
| 167 | boolean b1 = i1.hasNext(); |
| 168 | boolean b2 = i2.hasNext(); |
| 169 | assertEquals(b1, b2); |
| 170 | if (!b1) break; |
| 171 | assertEquals(i1.nextDoc(), i2.nextDoc()); |
| 172 | } |
| 173 | } |
| 174 | |
| 175 | protected void doSingle(int maxSize) { |
| 176 | int sz = rand.nextInt(maxSize + 1); |