示例#1
0
 @Test
 public void testCopy() {
   AsciiInputStream in = new AsciiInputStream("input");
   StringOutputStream out = new StringOutputStream();
   try {
     StreamUtil.copy(in, out);
   } catch (IOException ioex) {
     fail("StreamUtil.copy " + ioex.toString());
   }
   assertEquals("input", out.toString());
   StreamUtil.close(out);
   StreamUtil.close(in);
 }