Merge branch 'polish-urls-remaining-2.1.x' of https://github.com/spring-operator/spring-cloud-openfeign into spring-operator-polish-urls-remaining-2.1.x

This commit is contained in:
Ryan Baxter
2019-03-28 14:04:30 -04:00
8 changed files with 21 additions and 21 deletions

View File

@@ -101,7 +101,7 @@ public class FeignRibbonClientTests {
Request request = new RequestTemplate().method(GET).target("http://foo")
.resolve(new HashMap<>()).request();
this.client.execute(request, new Options());
RequestMatcher matcher = new RequestMatcher("http://foo.com:8000/");
RequestMatcher matcher = new RequestMatcher("https://foo.com:8000/");
verify(this.delegate).execute(argThat(matcher), any(Options.class));
}
@@ -110,16 +110,16 @@ public class FeignRibbonClientTests {
Request request = new RequestTemplate().method(GET).target("http://foo/")
.resolve(new HashMap<>()).request();
this.client.execute(request, new Options());
RequestMatcher matcher = new RequestMatcher("http://foo.com:8000/");
RequestMatcher matcher = new RequestMatcher("https://foo.com:8000/");
verify(this.delegate).execute(argThat(matcher), any(Options.class));
}
@Test
public void verifyCleanUrl() throws Exception {
Request request = new RequestTemplate().method(GET)
.target("http://tp/abc/bcd.json").resolve(new HashMap<>()).request();
.target("https://tp/abc/bcd.json").resolve(new HashMap<>()).request();
this.client.execute(request, new Options());
RequestMatcher matcher = new RequestMatcher("http://foo.com:8000/abc/bcd.json");
RequestMatcher matcher = new RequestMatcher("https://foo.com:8000/abc/bcd.json");
verify(this.delegate).execute(argThat(matcher), any(Options.class));
}

View File

@@ -48,7 +48,7 @@ public class RibbonResponseStatusCodeExceptionTest {
List<String> fooValues = new ArrayList<String>();
fooValues.add("bar");
headers.put("foo", fooValues);
Request request = Request.create(GET, "http://service.com",
Request request = Request.create(GET, "https://service.com",
new HashMap<String, Collection<String>>(), new byte[] {},
Charset.defaultCharset());
byte[] body = "foo".getBytes();

View File

@@ -69,7 +69,7 @@ public class FeignClientValidationTests {
@EnableFeignClients(clients = GoodUrlConfiguration.Client.class)
protected static class GoodUrlConfiguration {
@FeignClient(name = "example", url = "http://example.com")
@FeignClient(name = "example", url = "https://example.com")
interface Client {
@RequestMapping(method = RequestMethod.GET, value = "/")
@@ -85,7 +85,7 @@ public class FeignClientValidationTests {
@EnableFeignClients(clients = PlaceholderUrlConfiguration.Client.class)
protected static class PlaceholderUrlConfiguration {
@FeignClient(name = "example", url = "${feignClient.url:http://example.com}")
@FeignClient(name = "example", url = "${feignClient.url:https://example.com}")
interface Client {
@RequestMapping(method = RequestMethod.GET, value = "/")