mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-08-29 03:06:45 +08:00
Polish
This commit is contained in:
parent
c71f562001
commit
38dc9ec441
@ -3297,7 +3297,7 @@ You can inject an auto-configured `ElasticsearchTemplate` or Elasticsearch `Clie
|
||||
instance as you would any other Spring Bean. By default the instance will embed a
|
||||
local in-memory server (a `Node` in ElasticSearch terms) and use the current working
|
||||
directory as the home directory for the server. In this setup, the first thing to do
|
||||
is to tell ElasticSearch were to store its files:
|
||||
is to tell ElasticSearch where to store its files:
|
||||
|
||||
[source,properties,indent=0]
|
||||
----
|
||||
@ -4401,7 +4401,7 @@ Spring Boot provides Spring Session auto-configuration for a wide range of store
|
||||
* Hazelcast
|
||||
* HashMap
|
||||
|
||||
If Spring Session is available, you only need to chose the
|
||||
If Spring Session is available, you only need to choose the
|
||||
{sc-spring-boot-autoconfigure}/session/StoreType.{sc-ext}[`StoreType`] that you wish to
|
||||
use to store the sessions. For instance to use Redis as backend store, you'd configure
|
||||
your application as follows:
|
||||
|
@ -26,7 +26,7 @@ import org.junit.Test;
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
/**
|
||||
* Tests for configuring a project's main class
|
||||
* Tests for configuring a project's main class.
|
||||
*
|
||||
* @author Dave Syer
|
||||
* @author Andy Wilkinson
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Home directory of the embedded elastic instance. Default to the
|
||||
# Home directory of the embedded Elasticsearch instance. Default to the
|
||||
# current working directory.
|
||||
#
|
||||
spring.data.elasticsearch.properties.path.home=target/elastic
|
||||
|
@ -41,7 +41,7 @@ import static org.mockito.Mockito.verify;
|
||||
*
|
||||
* @author Phillip Webb
|
||||
*/
|
||||
public class MockitoInitializeTestExecutionListenerTests {
|
||||
public class MockitoTestExecutionListenerTests {
|
||||
|
||||
private MockitoTestExecutionListener listener = new MockitoTestExecutionListener();
|
||||
|
@ -30,7 +30,7 @@ import static org.assertj.core.api.Assertions.assertThat;
|
||||
import static org.mockito.Mockito.verify;
|
||||
|
||||
/**
|
||||
* Test {@link SpyBean} on a test class can be used to inject new mock instances.
|
||||
* Test {@link SpyBean} on a test class can be used to inject new spy instances.
|
||||
*
|
||||
* @author Phillip Webb
|
||||
*/
|
||||
|
@ -31,7 +31,7 @@ import static org.assertj.core.api.Assertions.assertThat;
|
||||
import static org.mockito.Mockito.verify;
|
||||
|
||||
/**
|
||||
* Test {@link SpyBean} on a test class field can be used to inject new mock instances.
|
||||
* Test {@link SpyBean} on a test class field can be used to inject new spy instances.
|
||||
*
|
||||
* @author Phillip Webb
|
||||
*/
|
||||
|
@ -40,7 +40,7 @@ public class SpyDefinitionTests {
|
||||
public ExpectedException thrown = ExpectedException.none();
|
||||
|
||||
@Test
|
||||
public void ClassToSpyMustNotBeNull() throws Exception {
|
||||
public void classToSpyMustNotBeNull() throws Exception {
|
||||
this.thrown.expect(IllegalArgumentException.class);
|
||||
this.thrown.expectMessage("ClassToSpy must not be null");
|
||||
new SpyDefinition(null, null, null);
|
||||
|
@ -148,7 +148,7 @@ public class JettyEmbeddedServletContainerFactory
|
||||
/**
|
||||
* Create a new {@link JettyEmbeddedServletContainerFactory} with the specified
|
||||
* context path and port.
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param port the port to listen on
|
||||
*/
|
||||
public JettyEmbeddedServletContainerFactory(String contextPath, int port) {
|
||||
|
@ -143,7 +143,7 @@ public class TomcatEmbeddedServletContainerFactory
|
||||
/**
|
||||
* Create a new {@link TomcatEmbeddedServletContainerFactory} with the specified
|
||||
* context path and port.
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param port the port to listen on
|
||||
*/
|
||||
public TomcatEmbeddedServletContainerFactory(String contextPath, int port) {
|
||||
|
@ -92,7 +92,7 @@ public class UndertowEmbeddedServletContainer implements EmbeddedServletContaine
|
||||
* Create a new {@link UndertowEmbeddedServletContainer} instance.
|
||||
* @param builder the builder
|
||||
* @param manager the deployment manager
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param port the port to listen on (not used)
|
||||
* @param autoStart if the server should be started
|
||||
* @param compression compression configuration
|
||||
@ -109,7 +109,7 @@ public class UndertowEmbeddedServletContainer implements EmbeddedServletContaine
|
||||
* Create a new {@link UndertowEmbeddedServletContainer} instance.
|
||||
* @param builder the builder
|
||||
* @param manager the deployment manager
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param port the port to listen on (not used)
|
||||
* @param useForwardHeaders if x-forward headers should be used
|
||||
* @param autoStart if the server should be started
|
||||
@ -128,12 +128,12 @@ public class UndertowEmbeddedServletContainer implements EmbeddedServletContaine
|
||||
* Create a new {@link UndertowEmbeddedServletContainer} instance.
|
||||
* @param builder the builder
|
||||
* @param manager the deployment manager
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param port the port to listen on (not used)
|
||||
* @param useForwardHeaders if x-forward headers should be used
|
||||
* @param autoStart if the server should be started
|
||||
* @param compression compression configuration
|
||||
* @param serverHeader string to be used in http header
|
||||
* @param serverHeader string to be used in HTTP header
|
||||
* @deprecated as of 1.4 in favor of
|
||||
* {@link #UndertowEmbeddedServletContainer(Builder, DeploymentManager, String, boolean, boolean, Compression, String)}
|
||||
*/
|
||||
@ -149,7 +149,7 @@ public class UndertowEmbeddedServletContainer implements EmbeddedServletContaine
|
||||
* Create a new {@link UndertowEmbeddedServletContainer} instance.
|
||||
* @param builder the builder
|
||||
* @param manager the deployment manager
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param autoStart if the server should be started
|
||||
* @param compression compression configuration
|
||||
*/
|
||||
@ -162,7 +162,7 @@ public class UndertowEmbeddedServletContainer implements EmbeddedServletContaine
|
||||
* Create a new {@link UndertowEmbeddedServletContainer} instance.
|
||||
* @param builder the builder
|
||||
* @param manager the deployment manager
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param useForwardHeaders if x-forward headers should be used
|
||||
* @param autoStart if the server should be started
|
||||
* @param compression compression configuration
|
||||
@ -178,11 +178,11 @@ public class UndertowEmbeddedServletContainer implements EmbeddedServletContaine
|
||||
* Create a new {@link UndertowEmbeddedServletContainer} instance.
|
||||
* @param builder the builder
|
||||
* @param manager the deployment manager
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param useForwardHeaders if x-forward headers should be used
|
||||
* @param autoStart if the server should be started
|
||||
* @param compression compression configuration
|
||||
* @param serverHeader string to be used in http header
|
||||
* @param serverHeader string to be used in HTTP header
|
||||
*/
|
||||
public UndertowEmbeddedServletContainer(Builder builder, DeploymentManager manager,
|
||||
String contextPath, boolean useForwardHeaders, boolean autoStart,
|
||||
|
@ -144,7 +144,7 @@ public class UndertowEmbeddedServletContainerFactory
|
||||
/**
|
||||
* Create a new {@link UndertowEmbeddedServletContainerFactory} with the specified
|
||||
* context path and port.
|
||||
* @param contextPath root the context path
|
||||
* @param contextPath the root context path
|
||||
* @param port the port to listen on
|
||||
*/
|
||||
public UndertowEmbeddedServletContainerFactory(String contextPath, int port) {
|
||||
|
@ -376,8 +376,6 @@ public class ConfigFileApplicationListenerTests {
|
||||
@Test
|
||||
public void loadPropertiesThenProfilePropertiesWithOverride() throws Exception {
|
||||
this.environment.setActiveProfiles("other");
|
||||
// TestPropertySourceUtils.addInlinedPropertiesToEnvironment(this.environment,
|
||||
// "spring.profiles.active:other");
|
||||
this.initializer.setSearchNames("enableprofile");
|
||||
this.initializer.postProcessEnvironment(this.environment, this.application);
|
||||
String property = this.environment.getProperty("other.property");
|
||||
|
Loading…
Reference in New Issue
Block a user