Search in sources :

Example 46 with ISOPackager

use of org.jpos.iso.ISOPackager in project jPOS by jpos.

the class RawChannelTest method testConstructor1.

@Test
public void testConstructor1() throws Throwable {
    byte[] header = new byte[3];
    ISOPackager p = new ISOBaseValidatingPackager();
    RawChannel rawChannel = new RawChannel("testRawChannelHost", 100, p, header);
    assertEquals(0, rawChannel.getIncomingFilters().size(), "rawChannel.getIncomingFilters().size()");
    assertEquals(100000, rawChannel.getMaxPacketLength(), "rawChannel.getMaxPacketLength()");
    assertSame(p, rawChannel.getPackager(), "rawChannel.getPackager()");
    assertEquals(100, rawChannel.getPort(), "rawChannel.getPort()");
    assertEquals("", rawChannel.getName(), "rawChannel.getName()");
    assertEquals(3, rawChannel.getCounters().length, "rawChannel.getCounters().length");
    assertNull(rawChannel.getLogger(), "rawChannel.getLogger()");
    assertNull(rawChannel.getSocketFactory(), "rawChannel.getSocketFactory()");
    assertSame(header, rawChannel.getHeader(), "rawChannel.getHeader()");
    assertEquals(0, rawChannel.getOutgoingFilters().size(), "rawChannel.getOutgoingFilters().size()");
    assertNull(rawChannel.getServerSocket(), "rawChannel.getServerSocket()");
    assertEquals("org.jpos.iso.channel.RawChannel", rawChannel.getOriginalRealm(), "rawChannel.getOriginalRealm()");
    assertNull(rawChannel.getRealm(), "rawChannel.getRealm()");
    assertEquals("testRawChannelHost", rawChannel.getHost(), "rawChannel.getHost()");
}
Also used : ISOPackager(org.jpos.iso.ISOPackager) ISOBaseValidatingPackager(org.jpos.iso.packager.ISOBaseValidatingPackager) Test(org.junit.jupiter.api.Test)

Aggregations

ISOPackager (org.jpos.iso.ISOPackager)46 Test (org.junit.jupiter.api.Test)42 ServerSocket (java.net.ServerSocket)12 ISOBaseValidatingPackager (org.jpos.iso.packager.ISOBaseValidatingPackager)5 ISO93APackager (org.jpos.iso.packager.ISO93APackager)4 ISOMsg (org.jpos.iso.ISOMsg)3 Base1Packager (org.jpos.iso.packager.Base1Packager)3 CTCSubFieldPackager (org.jpos.iso.packager.CTCSubFieldPackager)3 GenericPackager (org.jpos.iso.packager.GenericPackager)3 ISO87APackagerBBitmap (org.jpos.iso.packager.ISO87APackagerBBitmap)3 ISO87BPackager (org.jpos.iso.packager.ISO87BPackager)3 PostPackager (org.jpos.iso.packager.PostPackager)3 XMLPackager (org.jpos.iso.packager.XMLPackager)3 GenericValidatingPackager (org.jpos.iso.packager.GenericValidatingPackager)2 ISO87APackager (org.jpos.iso.packager.ISO87APackager)2 ISO93BPackager (org.jpos.iso.packager.ISO93BPackager)2 ListSelectionEvent (javax.swing.event.ListSelectionEvent)1 ListSelectionListener (javax.swing.event.ListSelectionListener)1 AbstractTableModel (javax.swing.table.AbstractTableModel)1 TableModel (javax.swing.table.TableModel)1