Package org.mokai.connector.smpp

Examples of org.mokai.connector.smpp.SmppServerConnector.doStop()


    Assert.assertEquals(message.getProperty("text", String.class), "This is a test");

    connection.unbind();
    connection.closeLink();

    connector.doStop();
  }

  @Test
  public void shouldFailToBindIfBadSystemId() throws Exception {
    SmppServerConnector connector = new SmppServerConnector();
View Full Code Here


    BindResp bindResp = connection.bind(Connection.TRANSMITTER, "test", "test", null);
    Assert.assertNotNull(bindResp);
    Assert.assertEquals(bindResp.getCommandStatus(), Response.INVALID_SYSTEM_ID.getCommandStatus());

    connector.doStop();
  }

  @Test
  public void shouldFailToBindIfBadPassword() throws Exception {
    SmppServerConfiguration configuration = new SmppServerConfiguration();
View Full Code Here

    Connection connection = connect(4444);
    BindResp bindResp = connection.bind(Connection.TRANSMITTER, "test", "other", null);
    Assert.assertNotNull(bindResp);
    Assert.assertEquals(bindResp.getCommandStatus(), Response.INVALID_PASSWORD.getCommandStatus());

    connector.doStop();
  }

  @Test
  public void shouldProduceDeliverSm() throws Exception {
    SmppServerConfiguration configuration = new SmppServerConfiguration();
View Full Code Here

    Assert.assertEquals(deliverSm.getEsmClass(), (byte) 0);
    Assert.assertEquals(deliverSm.getSource().getAddress(), "2222");
    Assert.assertEquals(deliverSm.getDestination().getAddress(), "1111");
    Assert.assertEquals(deliverSm.getMessageText(), "This is a test");

    connector.doStop();
  }

  @Test
  public void shouldProduceDeliveryReceipt() throws Exception {
    SmppServerConfiguration configuration = new SmppServerConfiguration();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.