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
6d6d76ca
Commit
6d6d76ca
authored
Mar 16, 2017
by
Stephane Nicoll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Polish
See gh-8543
parent
0b1d32e7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
SpringBootTestReactiveWebEnvironmentUserDefinedTestRestTemplateTests.java
...activeWebEnvironmentUserDefinedTestRestTemplateTests.java
+1
-2
SpringBootTestUserDefinedTestRestTemplateTests.java
...ntext/SpringBootTestUserDefinedTestRestTemplateTests.java
+3
-2
No files found.
spring-boot-test/src/test/java/org/springframework/boot/test/context/SpringBootTestReactiveWebEnvironmentUserDefinedTestRestTemplateTests.java
View file @
6d6d76ca
...
...
@@ -20,7 +20,6 @@ import org.junit.Test;
import
org.junit.runner.RunWith
;
import
org.springframework.boot.test.context.SpringBootTest.WebEnvironment
;
import
org.springframework.boot.test.web.client.TestRestTemplate
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.test.annotation.DirtiesContext
;
...
...
@@ -33,7 +32,7 @@ import static org.assertj.core.api.Assertions.assertThat;
/**
* Tests for {@link SpringBootTest} in a reactive environment configured with
* a user-defined {@link
T
estRestTemplate}.
* a user-defined {@link
RestTemplate} that is named {@code t
estRestTemplate}.
*
* @author Madhura Bhave
*/
...
...
spring-boot-test/src/test/java/org/springframework/boot/test/context/SpringBootTest
TestRestTemplateDefinedByUser
.java
→
spring-boot-test/src/test/java/org/springframework/boot/test/context/SpringBootTest
UserDefinedTestRestTemplateTests
.java
View file @
6d6d76ca
...
...
@@ -31,7 +31,8 @@ import org.springframework.web.servlet.config.annotation.EnableWebMvc;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
/**
* Tests for {@link SpringBootTest} configured with {@link WebEnvironment#RANDOM_PORT}.
* Tests for {@link SpringBootTest} configured with a user-defined {@link RestTemplate}
* that is named {@code testRestTemplate}.
*
* @author Phillip Webb
* @author Andy Wilkinson
...
...
@@ -39,7 +40,7 @@ import static org.assertj.core.api.Assertions.assertThat;
@RunWith
(
SpringRunner
.
class
)
@DirtiesContext
@SpringBootTest
(
webEnvironment
=
WebEnvironment
.
RANDOM_PORT
,
properties
=
{
"value=123"
})
public
class
SpringBootTest
TestRestTemplateDefinedByUser
public
class
SpringBootTest
UserDefinedTestRestTemplateTests
extends
AbstractSpringBootTestWebServerWebEnvironmentTests
{
@Test
...
...
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