try {
byte[] bytes = stringAsBytes(x) ;
ByteArrayInputStream bin = new ByteArrayInputStream(bytes) ;
// Create string from bytes
InStreamUTF8 r = new InStreamUTF8(bin) ;
//Get tests working.
//Reader r = new InputStreamReader(bin, utf8) ;
char[] cbuff = new char[x.length()*10] ; // Way too big
int len = r.read(cbuff) ;
String str = new String(cbuff, 0 , len) ;
assertEquals(x, str) ;
r.close();
} catch (IOException ex) { throw new RuntimeException(ex) ; }
}