Switch tests to properties that are not deprecated

Closes gh-29488
This commit is contained in:
Andy Wilkinson 2022-01-19 19:08:31 +00:00
parent ee9c399eba
commit 6bea2172cb
2 changed files with 5 additions and 6 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -55,7 +55,7 @@ class ElasticsearchRepositoriesAutoConfigurationTests {
private final ApplicationContextRunner contextRunner = new ApplicationContextRunner()
.withConfiguration(AutoConfigurations.of(ElasticsearchRestClientAutoConfiguration.class,
ElasticsearchRepositoriesAutoConfiguration.class, ElasticsearchDataAutoConfiguration.class))
.withPropertyValues("spring.elasticsearch.rest.uris=" + elasticsearch.getHttpHostAddress());
.withPropertyValues("spring.elasticsearch.uris=" + elasticsearch.getHttpHostAddress());
@Test
void testDefaultRepositoryConfiguration() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2021 the original author or authors.
* Copyright 2012-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -55,9 +55,8 @@ class ReactiveElasticsearchRepositoriesAutoConfigurationTests {
.withConfiguration(AutoConfigurations.of(ReactiveElasticsearchRestClientAutoConfiguration.class,
ReactiveElasticsearchRepositoriesAutoConfiguration.class, ElasticsearchDataAutoConfiguration.class))
.withPropertyValues(
"spring.data.elasticsearch.client.reactive.endpoints=" + elasticsearch.getHost() + ":"
+ elasticsearch.getFirstMappedPort(),
"spring.data.elasticsearch.client.reactive.socket-timeout=30s");
"spring.elasticsearch.uris=" + elasticsearch.getHost() + ":" + elasticsearch.getFirstMappedPort(),
"spring.elasticsearch.socket-timeout=30s");
@Test
void testDefaultRepositoryConfiguration() {