|
|
@ -16,6 +16,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
package org.springframework.boot.autoconfigure.data.elasticsearch;
|
|
|
|
package org.springframework.boot.autoconfigure.data.elasticsearch;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import java.time.Duration;
|
|
|
|
|
|
|
|
|
|
|
|
import org.junit.jupiter.api.AfterEach;
|
|
|
|
import org.junit.jupiter.api.AfterEach;
|
|
|
|
import org.junit.jupiter.api.BeforeEach;
|
|
|
|
import org.junit.jupiter.api.BeforeEach;
|
|
|
|
import org.junit.jupiter.api.Test;
|
|
|
|
import org.junit.jupiter.api.Test;
|
|
|
@ -51,7 +53,8 @@ import static org.mockito.Mockito.mock;
|
|
|
|
class ElasticsearchDataAutoConfigurationTests {
|
|
|
|
class ElasticsearchDataAutoConfigurationTests {
|
|
|
|
|
|
|
|
|
|
|
|
@Container
|
|
|
|
@Container
|
|
|
|
static final ElasticsearchContainer elasticsearch = new ElasticsearchContainer();
|
|
|
|
static ElasticsearchContainer elasticsearch = new ElasticsearchContainer().withStartupAttempts(5)
|
|
|
|
|
|
|
|
.withStartupTimeout(Duration.ofMinutes(2));
|
|
|
|
|
|
|
|
|
|
|
|
private ApplicationContextRunner contextRunner = new ApplicationContextRunner().withConfiguration(
|
|
|
|
private ApplicationContextRunner contextRunner = new ApplicationContextRunner().withConfiguration(
|
|
|
|
AutoConfigurations.of(ElasticsearchAutoConfiguration.class, RestClientAutoConfiguration.class,
|
|
|
|
AutoConfigurations.of(ElasticsearchAutoConfiguration.class, RestClientAutoConfiguration.class,
|
|
|
|