public void testPartialLine() throws Exception {
    String input1 = "this is a ";
    String input2 = "test\r\n";
    ByteBuffer b = ByteBuffer.allocate(20);
    SimpleOp op = new SimpleOp(OperationReadType.LINE);

    b.put(input1.getBytes());
    b.flip();
    op.readFromBuffer(b);
    assertNull(op.getCurrentLine());
    b.clear();
    b.put(input2.getBytes());
    b.flip();
    op.readFromBuffer(b);
    assertEquals("this is a test", op.getCurrentLine());
  }
Test the basic operation buffer handling stuff.
src/test/java/net/spy/memcached/protocol/ascii/BaseOpTest.java