}
@Test
public void testAcceptDataHandlerNoMTOM() throws Exception {
setupForTest(false);
DataHandlerBean dhBean = new DataHandlerBean();
dhBean.setName("some name");
// some day, we might need this to be longer than some threshold.
String someData = "This is the cereal shot from guns.";
DataHandler dataHandler = new DataHandler(someData, "text/plain;charset=utf-8");
dhBean.setDataHandler(dataHandler);
client.acceptDataHandler(dhBean);
DataHandlerBean accepted = impl.getLastDhBean();
Assert.assertNotNull(accepted);
InputStream data = accepted.getDataHandler().getInputStream();
Assert.assertNotNull(data);
String dataString = org.apache.commons.io.IOUtils.toString(data, "utf-8");
Assert.assertEquals("This is the cereal shot from guns.", dataString);
}