예제 #1
0
 public BSONTest() {
   for (int x = 8; x < 2048; x *= 2) {
     StringBuilder buf = new StringBuilder();
     while (buf.length() < x) buf.append(x);
     _data.add(buf.toString());
   }
 }
예제 #2
0
 @Test
 public void testOBBig1() {
   BasicOutputBuffer a = new BasicOutputBuffer();
   StringBuilder b = new StringBuilder();
   for (String x : _data) {
     a.write(x.getBytes());
     b.append(x);
   }
   assertEquals(a.asString(), b.toString());
 }