GH-1126 Fixed default app port in Tests
Ensured AggregateApplicationTests, AggregateWithMainTest and AggregationTest arn't using default 8080 port
This commit is contained in:
@@ -19,6 +19,7 @@ package org.springframework.cloud.stream.config.aggregate;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
import org.junit.Assert;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
|
||||
@@ -42,6 +43,11 @@ import static org.hamcrest.Matchers.notNullValue;
|
||||
@RunWith(SpringJUnit4ClassRunner.class)
|
||||
public class AggregateApplicationTests {
|
||||
|
||||
@Before
|
||||
public void before() {
|
||||
System.setProperty("server.port", "0");
|
||||
}
|
||||
|
||||
@Test
|
||||
@SuppressWarnings("unchecked")
|
||||
public void testAggregateApplication() throws Exception {
|
||||
|
||||
Reference in New Issue
Block a user