Merge pull request #1266 from spring-operator/polish-urls-remaining-master
URL Cleanup
This commit is contained in:
@@ -111,7 +111,7 @@ public class WebClientDiscoveryExceptionTests {
|
||||
@Test
|
||||
public void testTemplate() throws Exception {
|
||||
shouldCloseSpanUponException((ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://exceptionservice/", Map.class));
|
||||
.getForEntity("https://exceptionservice/", Map.class));
|
||||
}
|
||||
|
||||
@FeignClient("exceptionservice")
|
||||
|
||||
@@ -124,7 +124,7 @@ public class WebClientExceptionTests {
|
||||
(ResponseEntityProvider) (tests) -> tests.testFeignInterfaceWithException
|
||||
.shouldFailToConnect(),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://exceptionservice/", Map.class) };
|
||||
.getForEntity("https://exceptionservice/", Map.class) };
|
||||
}
|
||||
|
||||
@FeignClient("exceptionservice")
|
||||
|
||||
@@ -80,7 +80,7 @@ public class TracingFeignClientTests {
|
||||
try (Tracer.SpanInScope ws = this.tracer.withSpanInScope(span.start())) {
|
||||
this.traceFeignClient
|
||||
.execute(
|
||||
Request.create("GET", "http://foo", new HashMap<>(),
|
||||
Request.create("GET", "https://foo", new HashMap<>(),
|
||||
"".getBytes(), Charset.defaultCharset()),
|
||||
new Request.Options());
|
||||
}
|
||||
@@ -101,7 +101,7 @@ public class TracingFeignClientTests {
|
||||
try (Tracer.SpanInScope ws = this.tracer.withSpanInScope(span.start())) {
|
||||
this.traceFeignClient
|
||||
.execute(
|
||||
Request.create("GET", "http://foo", new HashMap<>(),
|
||||
Request.create("GET", "https://foo", new HashMap<>(),
|
||||
"".getBytes(), Charset.defaultCharset()),
|
||||
new Request.Options());
|
||||
BDDAssertions.fail("Exception should have been thrown");
|
||||
@@ -122,7 +122,7 @@ public class TracingFeignClientTests {
|
||||
public void should_shorten_the_span_name() throws IOException {
|
||||
this.traceFeignClient
|
||||
.execute(
|
||||
Request.create("GET", "http://foo/" + bigName(), new HashMap<>(),
|
||||
Request.create("GET", "https://foo/" + bigName(), new HashMap<>(),
|
||||
"".getBytes(), Charset.defaultCharset()),
|
||||
new Request.Options());
|
||||
|
||||
|
||||
@@ -208,21 +208,21 @@ public class WebClientTests {
|
||||
(ResponseEntityProvider) (tests) -> tests.testFeignInterface.getNoTrace(),
|
||||
(ResponseEntityProvider) (tests) -> tests.testFeignInterface.getNoTrace(),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/notrace", String.class),
|
||||
.getForEntity("https://fooservice/notrace", String.class),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/notrace", String.class),
|
||||
.getForEntity("https://fooservice/notrace", String.class),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/notrace", String.class),
|
||||
.getForEntity("https://fooservice/notrace", String.class),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/notrace", String.class),
|
||||
.getForEntity("https://fooservice/notrace", String.class),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/notrace", String.class),
|
||||
.getForEntity("https://fooservice/notrace", String.class),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/notrace", String.class),
|
||||
.getForEntity("https://fooservice/notrace", String.class),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/notrace", String.class),
|
||||
.getForEntity("https://fooservice/notrace", String.class),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/notrace", String.class) };
|
||||
.getForEntity("https://fooservice/notrace", String.class) };
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -251,7 +251,7 @@ public class WebClientTests {
|
||||
return new Object[] {
|
||||
(ResponseEntityProvider) (tests) -> tests.testFeignInterface.headers(),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/", Map.class) };
|
||||
.getForEntity("https://fooservice/", Map.class) };
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -407,7 +407,7 @@ public class WebClientTests {
|
||||
return new Object[] {
|
||||
(ResponseEntityProvider) (tests) -> tests.testFeignInterface.headers(),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/traceid", String.class) };
|
||||
.getForEntity("https://fooservice/traceid", String.class) };
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -432,13 +432,13 @@ public class WebClientTests {
|
||||
(ResponseEntityProvider) (tests) -> tests.testFeignInterface
|
||||
.noResponseBody(),
|
||||
(ResponseEntityProvider) (tests) -> tests.template
|
||||
.getForEntity("http://fooservice/noresponse", String.class) };
|
||||
.getForEntity("https://fooservice/noresponse", String.class) };
|
||||
}
|
||||
|
||||
@Test
|
||||
public void shouldCloseSpanWhenErrorControllerGetsCalled() {
|
||||
try {
|
||||
this.template.getForEntity("http://fooservice/nonExistent", String.class);
|
||||
this.template.getForEntity("https://fooservice/nonExistent", String.class);
|
||||
fail("An exception should be thrown");
|
||||
}
|
||||
catch (HttpClientErrorException e) {
|
||||
@@ -465,7 +465,7 @@ public class WebClientTests {
|
||||
|
||||
@Test
|
||||
public void shouldNotExecuteErrorControllerWhenUrlIsFound() {
|
||||
this.template.getForEntity("http://fooservice/notrace", String.class);
|
||||
this.template.getForEntity("https://fooservice/notrace", String.class);
|
||||
|
||||
then(this.tracer.currentSpan()).isNull();
|
||||
then(this.testErrorController.getSpan()).isNull();
|
||||
|
||||
Reference in New Issue
Block a user