junit.textui.TestRunner.main(testCaseName);
}
public void testInit() throws Exception {
ByteArrayOutputStream out = new ByteArrayOutputStream();
new HttpDataTransmitterMockup(out);
try {
new HttpDataTransmitterMockup(null);
fail("IllegalArgumentException should have been thrown");
} catch (IllegalArgumentException ex) {
//expected
}
ByteArrayInputStream in = new ByteArrayInputStream(out.toByteArray());
new HttpDataReceiverMockup(in, 10);
try {
new HttpDataReceiverMockup(in, -10);
fail("IllegalArgumentException should have been thrown");
} catch (IllegalArgumentException ex) {
//expected
}
try {
new HttpDataTransmitterMockup(out, -10);
fail("IllegalArgumentException should have been thrown");
} catch (IllegalArgumentException ex) {
//expected
}
try {