### Question:
KeyBuffer { public String drain() { String keybufContents = toString(); free(); return keybufContents; } KeyBuffer(); void add(String s); int size(); @Override String toString(); String drain(); void free();  }### Answer:
@Test public void testDrain(){ assertEquals(0, k.size()); k.add(doubleTestString); assertEquals(doubleTestString, k.drain()); assertEquals(0, k.size()); }