Introduced new module due to BAEL-598
This commit is contained in:
committed by
Victor Mosin
parent
5c85259243
commit
d8efbb5c75
@@ -0,0 +1,33 @@
|
||||
package com.baeldung.thrift;
|
||||
|
||||
import org.junit.After;
|
||||
import org.junit.Assert;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
|
||||
public class CrossPlatformServiceTest {
|
||||
|
||||
private CrossPlatformServiceServer server = new CrossPlatformServiceServer();
|
||||
|
||||
@Before
|
||||
public void setUp() {
|
||||
new Thread(() -> server.start()).start();
|
||||
try {
|
||||
// wait for the server start up
|
||||
Thread.sleep(1000);
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
@After
|
||||
public void tearDown() {
|
||||
server.stop();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void ping() {
|
||||
CrossPlatformServiceClient client = new CrossPlatformServiceClient();
|
||||
Assert.assertTrue(client.ping());
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user