use of org.jpos.iso.packager.EuroSubFieldPackager in project jPOS by jpos.
the class MD5FilterTest method testFilter.
@Test
public void testFilter() throws Throwable {
MD5Filter mD5Filter = new MD5Filter();
mD5Filter.setConfiguration(new SimpleConfiguration());
ISOMsg m = new ISOMsg("testMD5FilterMti");
m.setDirection(2);
ISOMsg result = mD5Filter.filter(new ASCIIChannel(new EuroSubFieldPackager()), m, new LogEvent());
assertEquals("m.getMaxField()", 128, m.getMaxField());
assertSame("result", m, result);
}
use of org.jpos.iso.packager.EuroSubFieldPackager in project jPOS by jpos.
the class QMUXTest method testProcessUnhandled.
@Test
public void testProcessUnhandled() throws Throwable {
ISOMsg m = new ISOMsg("testQMUXMti");
m.setSource(new PADChannel(new EuroSubFieldPackager()));
QMUX qMUX = new QMUX();
qMUX.processUnhandled(m);
assertEquals("qMUX.listeners.size()", 0, qMUX.listeners.size());
}
use of org.jpos.iso.packager.EuroSubFieldPackager in project jPOS by jpos.
the class StatefulFilterTest method testFilterThrowsNullPointerException7.
@Test
public void testFilterThrowsNullPointerException7() throws Throwable {
StatefulFilter statefulFilter = new StatefulFilter();
statefulFilter.setKey(null);
try {
statefulFilter.filter(new BASE24TCPChannel(new EuroSubFieldPackager()), new ISOMsg(), new LogEvent(new PostPackager(), "testStatefulFilterTag"));
fail("Expected NullPointerException to be thrown");
} catch (NullPointerException ex) {
assertNull("ex.getMessage()", ex.getMessage());
}
}
Aggregations