Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
f25469c9
Commit
f25469c9
authored
Apr 03, 2019
by
Phillip Webb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update formatting with spring-javaformat 0.0.9
See gh-16421
parent
cae6a823
Changes
32
Hide whitespace changes
Inline
Side-by-side
Showing
32 changed files
with
106 additions
and
90 deletions
+106
-90
SampleActuatorUiApplicationPortTests.java
...ple/actuator/ui/SampleActuatorUiApplicationPortTests.java
+3
-3
InsecureManagementPortAndPathSampleActuatorApplicationTests.java
...eManagementPortAndPathSampleActuatorApplicationTests.java
+4
-4
InsecureManagementSampleActuatorApplicationTests.java
...tor/InsecureManagementSampleActuatorApplicationTests.java
+3
-3
InsecureSampleActuatorApplicationTests.java
...mple/actuator/InsecureSampleActuatorApplicationTests.java
+3
-3
ManagementAddressActuatorApplicationTests.java
...e/actuator/ManagementAddressActuatorApplicationTests.java
+4
-4
ManagementPathSampleActuatorApplicationTests.java
...ctuator/ManagementPathSampleActuatorApplicationTests.java
+3
-3
ManagementPortAndPathSampleActuatorApplicationTests.java
.../ManagementPortAndPathSampleActuatorApplicationTests.java
+3
-3
ManagementPortSampleActuatorApplicationTests.java
...ctuator/ManagementPortSampleActuatorApplicationTests.java
+3
-3
NoManagementSampleActuatorApplicationTests.java
.../actuator/NoManagementSampleActuatorApplicationTests.java
+3
-3
NonSensitiveHealthTests.java
...rc/test/java/sample/actuator/NonSensitiveHealthTests.java
+3
-3
ServletPathInsecureSampleActuatorApplicationTests.java
...or/ServletPathInsecureSampleActuatorApplicationTests.java
+3
-3
ServletPathSampleActuatorApplicationTests.java
...e/actuator/ServletPathSampleActuatorApplicationTests.java
+3
-3
ChatService.java
...mosphere/src/main/java/sample/atmosphere/ChatService.java
+3
-2
SampleAtmosphereApplicationTests.java
...a/sample/atmosphere/SampleAtmosphereApplicationTests.java
+3
-2
SampleCassandraApplicationTests.java
...ample/data/cassandra/SampleCassandraApplicationTests.java
+3
-3
Customer.java
...rch/src/main/java/sample/data/elasticsearch/Customer.java
+3
-2
SampleDataJpaApplicationTests.java
...t/java/sample/data/jpa/SampleDataJpaApplicationTests.java
+3
-3
SampleHibernate4ApplicationTests.java
...a/sample/hibernate4/SampleHibernate4ApplicationTests.java
+3
-3
SampleHibernate52ApplicationTests.java
...sample/hibernate52/SampleHibernate52ApplicationTests.java
+3
-3
SampleHypermediaUiSecureApplicationTests.java
...a/ui/secure/SampleHypermediaUiSecureApplicationTests.java
+3
-3
SampleHypermediaUiSecureApplicationWithContextPathTests.java
...pleHypermediaUiSecureApplicationWithContextPathTests.java
+3
-3
SampleHypermediaUiApplicationTests.java
...ple/hypermedia/ui/SampleHypermediaUiApplicationTests.java
+3
-3
SampleRedisExportApplicationTests.java
...mple/metrics/redis/SampleRedisExportApplicationTests.java
+3
-2
NonAutoConfigurationSampleTomcatApplicationTests.java
...cat/NonAutoConfigurationSampleTomcatApplicationTests.java
+3
-3
SampleWebSocketsApplicationTests.java
...les/websocket/jetty/SampleWebSocketsApplicationTests.java
+3
-2
CustomContainerWebSocketsApplicationTests.java
...jetty/echo/CustomContainerWebSocketsApplicationTests.java
+5
-3
SampleWebSocketsApplicationTests.java
...s/websocket/jetty93/SampleWebSocketsApplicationTests.java
+3
-2
CustomContainerWebSocketsApplicationTests.java
...tty93/echo/CustomContainerWebSocketsApplicationTests.java
+5
-3
SampleWebSocketsApplicationTests.java
...es/websocket/tomcat/SampleWebSocketsApplicationTests.java
+3
-2
CustomContainerWebSocketsApplicationTests.java
...omcat/echo/CustomContainerWebSocketsApplicationTests.java
+5
-3
SampleWebSocketsApplicationTests.java
.../websocket/undertow/SampleWebSocketsApplicationTests.java
+3
-2
CustomContainerWebSocketsApplicationTests.java
...ertow/echo/CustomContainerWebSocketsApplicationTests.java
+5
-3
No files found.
spring-boot-samples/spring-boot-sample-actuator-ui/src/test/java/sample/actuator/ui/SampleActuatorUiApplicationPortTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.port:0"
})
properties
=
{
"management.port:0"
})
@DirtiesContext
@DirtiesContext
public
class
SampleActuatorUiApplicationPortTests
{
public
class
SampleActuatorUiApplicationPortTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/InsecureManagementPortAndPathSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -41,9 +41,9 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -41,9 +41,9 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.port=0"
,
"management.context-path=/admin"
,
properties
=
{
"management.port=0"
,
"management.context-path=/admin"
,
"management.security.enabled=false"
})
"management.security.enabled=false"
})
@DirtiesContext
@DirtiesContext
public
class
InsecureManagementPortAndPathSampleActuatorApplicationTests
{
public
class
InsecureManagementPortAndPathSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/InsecureManagementSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -40,8 +40,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -40,8 +40,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.security.enabled:false"
})
properties
=
{
"management.security.enabled:false"
})
@DirtiesContext
@DirtiesContext
@ActiveProfiles
(
"unsecure-management"
)
@ActiveProfiles
(
"unsecure-management"
)
public
class
InsecureManagementSampleActuatorApplicationTests
{
public
class
InsecureManagementSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/InsecureSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"security.basic.enabled:false"
})
properties
=
{
"security.basic.enabled:false"
})
@DirtiesContext
@DirtiesContext
public
class
InsecureSampleActuatorApplicationTests
{
public
class
InsecureSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/ManagementAddressActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -39,9 +39,9 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -39,9 +39,9 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.port=0"
,
"management.address=127.0.0.1"
,
properties
=
{
"management.port=0"
,
"management.address=127.0.0.1"
,
"management.context-path:/admin"
})
"management.context-path:/admin"
})
@DirtiesContext
@DirtiesContext
public
class
ManagementAddressActuatorApplicationTests
{
public
class
ManagementAddressActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/ManagementPathSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -38,8 +38,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -38,8 +38,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.context_path=/admin"
})
properties
=
{
"management.context_path=/admin"
})
@DirtiesContext
@DirtiesContext
public
class
ManagementPathSampleActuatorApplicationTests
{
public
class
ManagementPathSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/ManagementPortAndPathSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -41,8 +41,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -41,8 +41,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.port=0"
,
"management.context-path=/admin"
})
properties
=
{
"management.port=0"
,
"management.context-path=/admin"
})
@DirtiesContext
@DirtiesContext
public
class
ManagementPortAndPathSampleActuatorApplicationTests
{
public
class
ManagementPortAndPathSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/ManagementPortSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -41,8 +41,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -41,8 +41,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.port=0"
})
properties
=
{
"management.port=0"
})
@DirtiesContext
@DirtiesContext
public
class
ManagementPortSampleActuatorApplicationTests
{
public
class
ManagementPortSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/NoManagementSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.port=-1"
})
properties
=
{
"management.port=-1"
})
@DirtiesContext
@DirtiesContext
public
class
NoManagementSampleActuatorApplicationTests
{
public
class
NoManagementSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/NonSensitiveHealthTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -36,8 +36,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -36,8 +36,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Phillip Webb
* @author Phillip Webb
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"endpoints.health.sensitive=false"
})
properties
=
{
"endpoints.health.sensitive=false"
})
@DirtiesContext
@DirtiesContext
public
class
NonSensitiveHealthTests
{
public
class
NonSensitiveHealthTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/ServletPathInsecureSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"security.basic.enabled:false"
,
"server.servletPath:/spring"
})
properties
=
{
"security.basic.enabled:false"
,
"server.servletPath:/spring"
})
@DirtiesContext
@DirtiesContext
public
class
ServletPathInsecureSampleActuatorApplicationTests
{
public
class
ServletPathInsecureSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/ServletPathSampleActuatorApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -38,8 +38,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -38,8 +38,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"server.servletPath=/spring"
})
properties
=
{
"server.servletPath=/spring"
})
@DirtiesContext
@DirtiesContext
public
class
ServletPathSampleActuatorApplicationTests
{
public
class
ServletPathSampleActuatorApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-atmosphere/src/main/java/sample/atmosphere/ChatService.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
5
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -45,7 +45,8 @@ public class ChatService {
...
@@ -45,7 +45,8 @@ public class ChatService {
(
event
.
isCancelled
()
?
"cancelled"
:
"closed"
));
(
event
.
isCancelled
()
?
"cancelled"
:
"closed"
));
}
}
@org
.
atmosphere
.
config
.
service
.
Message
(
encoders
=
JacksonEncoderDecoder
.
class
,
decoders
=
JacksonEncoderDecoder
.
class
)
@org
.
atmosphere
.
config
.
service
.
Message
(
encoders
=
JacksonEncoderDecoder
.
class
,
decoders
=
JacksonEncoderDecoder
.
class
)
public
Message
onMessage
(
Message
message
)
throws
IOException
{
public
Message
onMessage
(
Message
message
)
throws
IOException
{
this
.
logger
.
info
(
"Author {} sent message {}"
,
message
.
getAuthor
(),
this
.
logger
.
info
(
"Author {} sent message {}"
,
message
.
getAuthor
(),
message
.
getMessage
());
message
.
getMessage
());
...
...
spring-boot-samples/spring-boot-sample-atmosphere/src/test/java/sample/atmosphere/SampleAtmosphereApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
7
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.handler.TextWebSocketHandler;
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.handler.TextWebSocketHandler;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
SampleAtmosphereApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@SpringBootTest
(
classes
=
SampleAtmosphereApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@DirtiesContext
@DirtiesContext
public
class
SampleAtmosphereApplicationTests
{
public
class
SampleAtmosphereApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-data-cassandra/src/test/java/sample/data/cassandra/SampleCassandraApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
...
@@ -39,8 +39,8 @@ import static org.assertj.core.api.Assertions.assertThat;
* Tests for {@link SampleCassandraApplication}.
* Tests for {@link SampleCassandraApplication}.
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@TestExecutionListeners
(
mergeMode
=
MergeMode
.
MERGE_WITH_DEFAULTS
,
listeners
=
{
@TestExecutionListeners
(
mergeMode
=
MergeMode
.
MERGE_WITH_DEFAULTS
,
OrderedCassandraTestExecutionListener
.
class
})
listeners
=
{
OrderedCassandraTestExecutionListener
.
class
})
@SpringBootTest
@SpringBootTest
@CassandraDataSet
(
keyspace
=
"mykeyspace"
,
value
=
"setup.cql"
)
@CassandraDataSet
(
keyspace
=
"mykeyspace"
,
value
=
"setup.cql"
)
@EmbeddedCassandra
(
timeout
=
60000
)
@EmbeddedCassandra
(
timeout
=
60000
)
...
...
spring-boot-samples/spring-boot-sample-data-elasticsearch/src/main/java/sample/data/elasticsearch/Customer.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
3
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -19,7 +19,8 @@ package sample.data.elasticsearch;
...
@@ -19,7 +19,8 @@ package sample.data.elasticsearch;
import
org.springframework.data.annotation.Id
;
import
org.springframework.data.annotation.Id
;
import
org.springframework.data.elasticsearch.annotations.Document
;
import
org.springframework.data.elasticsearch.annotations.Document
;
@Document
(
indexName
=
"customer"
,
type
=
"customer"
,
shards
=
1
,
replicas
=
0
,
refreshInterval
=
"-1"
)
@Document
(
indexName
=
"customer"
,
type
=
"customer"
,
shards
=
1
,
replicas
=
0
,
refreshInterval
=
"-1"
)
public
class
Customer
{
public
class
Customer
{
@Id
@Id
...
...
spring-boot-samples/spring-boot-sample-data-jpa/src/test/java/sample/data/jpa/SampleDataJpaApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -47,8 +47,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
...
@@ -47,8 +47,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
@SpringBootTest
// Enable JMX so we can test the MBeans (you can't do this in a properties file)
// Enable JMX so we can test the MBeans (you can't do this in a properties file)
@TestPropertySource
(
properties
=
{
"spring.jmx.enabled:true"
,
@TestPropertySource
(
"spring.datasource.jmx-enabled:true"
})
properties
=
{
"spring.jmx.enabled:true"
,
"spring.datasource.jmx-enabled:true"
})
@ActiveProfiles
(
"scratch"
)
@ActiveProfiles
(
"scratch"
)
// Separate profile for web tests to avoid clashing databases
// Separate profile for web tests to avoid clashing databases
public
class
SampleDataJpaApplicationTests
{
public
class
SampleDataJpaApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-hibernate4/src/test/java/sample/hibernate4/SampleHibernate4ApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -47,8 +47,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
...
@@ -47,8 +47,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
@SpringBootTest
// Enable JMX so we can test the MBeans (you can't do this in a properties file)
// Enable JMX so we can test the MBeans (you can't do this in a properties file)
@TestPropertySource
(
properties
=
{
"spring.jmx.enabled:true"
,
@TestPropertySource
(
"spring.datasource.jmx-enabled:true"
})
properties
=
{
"spring.jmx.enabled:true"
,
"spring.datasource.jmx-enabled:true"
})
@ActiveProfiles
(
"scratch"
)
@ActiveProfiles
(
"scratch"
)
// Separate profile for web tests to avoid clashing databases
// Separate profile for web tests to avoid clashing databases
public
class
SampleHibernate4ApplicationTests
{
public
class
SampleHibernate4ApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-hibernate52/src/test/java/sample/hibernate52/SampleHibernate52ApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -47,8 +47,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
...
@@ -47,8 +47,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
@SpringBootTest
// Enable JMX so we can test the MBeans (you can't do this in a properties file)
// Enable JMX so we can test the MBeans (you can't do this in a properties file)
@TestPropertySource
(
properties
=
{
"spring.jmx.enabled:true"
,
@TestPropertySource
(
"spring.datasource.jmx-enabled:true"
})
properties
=
{
"spring.jmx.enabled:true"
,
"spring.datasource.jmx-enabled:true"
})
@ActiveProfiles
(
"scratch"
)
@ActiveProfiles
(
"scratch"
)
// Separate profile for web tests to avoid clashing databases
// Separate profile for web tests to avoid clashing databases
public
class
SampleHibernate52ApplicationTests
{
public
class
SampleHibernate52ApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-hypermedia-ui-secure/src/test/java/sample/hypermedia/ui/secure/SampleHypermediaUiSecureApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
8
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -29,8 +29,8 @@ import org.springframework.test.context.junit4.SpringRunner;
...
@@ -29,8 +29,8 @@ import org.springframework.test.context.junit4.SpringRunner;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
SpringBootTest
.
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
SpringBootTest
.
WebEnvironment
.
RANDOM_PORT
,
"endpoints.env.sensitive=false"
,
"foo=bar"
})
properties
=
{
"endpoints.env.sensitive=false"
,
"foo=bar"
})
public
class
SampleHypermediaUiSecureApplicationTests
{
public
class
SampleHypermediaUiSecureApplicationTests
{
@Autowired
@Autowired
...
...
spring-boot-samples/spring-boot-sample-hypermedia-ui-secure/src/test/java/sample/hypermedia/ui/secure/SampleHypermediaUiSecureApplicationWithContextPathTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
7
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -29,8 +29,8 @@ import org.springframework.test.context.junit4.SpringRunner;
...
@@ -29,8 +29,8 @@ import org.springframework.test.context.junit4.SpringRunner;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
SpringBootTest
.
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
SpringBootTest
.
WebEnvironment
.
RANDOM_PORT
,
"management.context-path=/admin"
})
properties
=
{
"management.context-path=/admin"
})
public
class
SampleHypermediaUiSecureApplicationWithContextPathTests
{
public
class
SampleHypermediaUiSecureApplicationWithContextPathTests
{
@Autowired
@Autowired
...
...
spring-boot-samples/spring-boot-sample-hypermedia-ui/src/test/java/sample/hypermedia/ui/SampleHypermediaUiApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -35,8 +35,8 @@ import org.springframework.test.context.junit4.SpringRunner;
...
@@ -35,8 +35,8 @@ import org.springframework.test.context.junit4.SpringRunner;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
"management.context-path="
})
properties
=
{
"management.context-path="
})
public
class
SampleHypermediaUiApplicationTests
{
public
class
SampleHypermediaUiApplicationTests
{
@Autowired
@Autowired
...
...
spring-boot-samples/spring-boot-sample-metrics-redis/src/test/java/sample/metrics/redis/SampleRedisExportApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
6
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -30,7 +30,8 @@ import org.springframework.test.context.junit4.SpringRunner;
...
@@ -30,7 +30,8 @@ import org.springframework.test.context.junit4.SpringRunner;
* @author Dave Syer
* @author Dave Syer
*/
*/
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
"spring.jmx.enabled=true"
)
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
"spring.jmx.enabled=true"
)
@DirtiesContext
@DirtiesContext
public
class
SampleRedisExportApplicationTests
{
public
class
SampleRedisExportApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-tomcat/src/test/java/sample/tomcat/NonAutoConfigurationSampleTomcatApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
8
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -68,8 +68,8 @@ public class NonAutoConfigurationSampleTomcatApplicationTests {
...
@@ -68,8 +68,8 @@ public class NonAutoConfigurationSampleTomcatApplicationTests {
ServerPropertiesAutoConfiguration
.
class
,
WebMvcAutoConfiguration
.
class
,
ServerPropertiesAutoConfiguration
.
class
,
WebMvcAutoConfiguration
.
class
,
HttpMessageConvertersAutoConfiguration
.
class
,
HttpMessageConvertersAutoConfiguration
.
class
,
PropertyPlaceholderAutoConfiguration
.
class
})
PropertyPlaceholderAutoConfiguration
.
class
})
@ComponentScan
(
basePackageClasses
=
{
SampleController
.
class
,
@ComponentScan
(
HelloWorldService
.
class
})
basePackageClasses
=
{
SampleController
.
class
,
HelloWorldService
.
class
})
public
static
class
NonAutoConfigurationSampleTomcatApplication
{
public
static
class
NonAutoConfigurationSampleTomcatApplication
{
public
static
void
main
(
String
[]
args
)
throws
Exception
{
public
static
void
main
(
String
[]
args
)
throws
Exception
{
...
...
spring-boot-samples/spring-boot-sample-websocket-jetty/src/test/java/samples/websocket/jetty/SampleWebSocketsApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
8
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
SampleJettyWebSocketsApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@SpringBootTest
(
classes
=
SampleJettyWebSocketsApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@DirtiesContext
@DirtiesContext
public
class
SampleWebSocketsApplicationTests
{
public
class
SampleWebSocketsApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-websocket-jetty/src/test/java/samples/websocket/jetty/echo/CustomContainerWebSocketsApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
7
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -50,8 +50,10 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
...
@@ -50,8 +50,10 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
{
SampleJettyWebSocketsApplication
.
class
,
@SpringBootTest
(
CustomContainerConfiguration
.
class
},
webEnvironment
=
WebEnvironment
.
DEFINED_PORT
)
classes
=
{
SampleJettyWebSocketsApplication
.
class
,
CustomContainerConfiguration
.
class
},
webEnvironment
=
WebEnvironment
.
DEFINED_PORT
)
@DirtiesContext
@DirtiesContext
public
class
CustomContainerWebSocketsApplicationTests
{
public
class
CustomContainerWebSocketsApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-websocket-jetty93/src/test/java/samples/websocket/jetty93/SampleWebSocketsApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
8
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
SampleJetty93WebSocketsApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@SpringBootTest
(
classes
=
SampleJetty93WebSocketsApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@DirtiesContext
@DirtiesContext
public
class
SampleWebSocketsApplicationTests
{
public
class
SampleWebSocketsApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-websocket-jetty93/src/test/java/samples/websocket/jetty93/echo/CustomContainerWebSocketsApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
7
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -50,8 +50,10 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
...
@@ -50,8 +50,10 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
{
SampleJetty93WebSocketsApplication
.
class
,
@SpringBootTest
(
CustomContainerConfiguration
.
class
},
webEnvironment
=
WebEnvironment
.
DEFINED_PORT
)
classes
=
{
SampleJetty93WebSocketsApplication
.
class
,
CustomContainerConfiguration
.
class
},
webEnvironment
=
WebEnvironment
.
DEFINED_PORT
)
@DirtiesContext
@DirtiesContext
public
class
CustomContainerWebSocketsApplicationTests
{
public
class
CustomContainerWebSocketsApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-websocket-tomcat/src/test/java/samples/websocket/tomcat/SampleWebSocketsApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
7
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
SampleTomcatWebSocketApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@SpringBootTest
(
classes
=
SampleTomcatWebSocketApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@DirtiesContext
@DirtiesContext
public
class
SampleWebSocketsApplicationTests
{
public
class
SampleWebSocketsApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-websocket-tomcat/src/test/java/samples/websocket/tomcat/echo/CustomContainerWebSocketsApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
7
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -50,8 +50,10 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
...
@@ -50,8 +50,10 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
{
SampleTomcatWebSocketApplication
.
class
,
@SpringBootTest
(
CustomContainerConfiguration
.
class
},
webEnvironment
=
WebEnvironment
.
DEFINED_PORT
)
classes
=
{
SampleTomcatWebSocketApplication
.
class
,
CustomContainerConfiguration
.
class
},
webEnvironment
=
WebEnvironment
.
DEFINED_PORT
)
@DirtiesContext
@DirtiesContext
public
class
CustomContainerWebSocketsApplicationTests
{
public
class
CustomContainerWebSocketsApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-websocket-undertow/src/test/java/samples/websocket/undertow/SampleWebSocketsApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
7
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
...
@@ -46,7 +46,8 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
SampleUndertowWebSocketsApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@SpringBootTest
(
classes
=
SampleUndertowWebSocketsApplication
.
class
,
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
)
@DirtiesContext
@DirtiesContext
public
class
SampleWebSocketsApplicationTests
{
public
class
SampleWebSocketsApplicationTests
{
...
...
spring-boot-samples/spring-boot-sample-websocket-undertow/src/test/java/samples/websocket/undertow/echo/CustomContainerWebSocketsApplicationTests.java
View file @
f25469c9
/*
/*
* Copyright 2012-201
7
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -50,8 +50,10 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
...
@@ -50,8 +50,10 @@ import org.springframework.web.socket.client.standard.StandardWebSocketClient;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
@RunWith
(
SpringRunner
.
class
)
@RunWith
(
SpringRunner
.
class
)
@SpringBootTest
(
classes
=
{
SampleUndertowWebSocketsApplication
.
class
,
@SpringBootTest
(
CustomContainerConfiguration
.
class
},
webEnvironment
=
WebEnvironment
.
DEFINED_PORT
)
classes
=
{
SampleUndertowWebSocketsApplication
.
class
,
CustomContainerConfiguration
.
class
},
webEnvironment
=
WebEnvironment
.
DEFINED_PORT
)
@DirtiesContext
@DirtiesContext
public
class
CustomContainerWebSocketsApplicationTests
{
public
class
CustomContainerWebSocketsApplicationTests
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment