use of org.apache.axis2.transport.testkit.tests.Setup in project wso2-axis2-transports by wso2.
the class JNDIEnvironment method setUp.
@Setup
@SuppressWarnings("unused")
private void setUp() throws Exception {
MockContextFactory.setAsInitial();
context = new InitialContext();
}
use of org.apache.axis2.transport.testkit.tests.Setup in project wso2-axis2-transports by wso2.
the class ActiveMQTestEnvironment method setUp.
@Setup
@SuppressWarnings("unused")
private void setUp() throws Exception {
broker = new BrokerService();
broker.setBrokerName(BROKER_NAME);
broker.setDataDirectory("target/activemq-data");
broker.setPersistenceAdapter(new MemoryPersistenceAdapter());
broker.start();
}
use of org.apache.axis2.transport.testkit.tests.Setup in project wso2-axis2-transports by wso2.
the class GreenMailTestEnvironment method setUp.
@Setup
@SuppressWarnings("unused")
private void setUp(LogManager logManager, PortAllocator portAllocator) throws Exception {
this.logManager = logManager;
this.portAllocator = portAllocator;
smtpServerSetup = new ServerSetup(portAllocator.allocatePort(), "127.0.0.1", ServerSetup.PROTOCOL_SMTP);
storeServerSetup = new ServerSetup(portAllocator.allocatePort(), "127.0.0.1", protocol);
greenMail = new GreenMail(new ServerSetup[] { smtpServerSetup, storeServerSetup });
greenMail.start();
smtpTunnel = new Tunnel(new InetSocketAddress("127.0.0.1", smtpServerSetup.getPort()));
smtpTunnel.start();
unallocatedAccounts = new LinkedList<Account>();
ServerUtil.waitForServer(smtpServerSetup.getPort());
ServerUtil.waitForServer(storeServerSetup.getPort());
}
Aggregations