mirror of
https://github.com/spring-projects/spring-boot.git
synced 2026-10-10 19:39:01 +00:00
Use HTTPS for external links wherever possible
See gh-16276
This commit is contained in:
committed by
Andy Wilkinson
parent
878a635bfb
commit
fb242c27d2
+4
-4
@@ -72,19 +72,19 @@ public class InitCommandTests extends AbstractHttpClientMockTests {
|
||||
@Test
|
||||
public void listServiceCapabilitiesText() throws Exception {
|
||||
mockSuccessfulMetadataTextGet();
|
||||
this.command.run("--list", "--target=http://fake-service");
|
||||
this.command.run("--list", "--target=https://fake-service");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void listServiceCapabilities() throws Exception {
|
||||
mockSuccessfulMetadataGet(true);
|
||||
this.command.run("--list", "--target=http://fake-service");
|
||||
this.command.run("--list", "--target=https://fake-service");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void listServiceCapabilitiesV2() throws Exception {
|
||||
mockSuccessfulMetadataGetV2(true);
|
||||
this.command.run("--list", "--target=http://fake-service");
|
||||
this.command.run("--list", "--target=https://fake-service");
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -357,7 +357,7 @@ public class InitCommandTests extends AbstractHttpClientMockTests {
|
||||
|
||||
@Test
|
||||
public void userAgent() throws Exception {
|
||||
this.command.run("--list", "--target=http://fake-service");
|
||||
this.command.run("--list", "--target=https://fake-service");
|
||||
verify(this.http).execute(this.requestCaptor.capture());
|
||||
Header agent = this.requestCaptor.getValue().getHeaders("User-Agent")[0];
|
||||
assertThat(agent.getValue()).startsWith("SpringBootCli/");
|
||||
|
||||
+1
-1
@@ -38,7 +38,7 @@ public class InitializrServiceTests extends AbstractHttpClientMockTests {
|
||||
@Test
|
||||
public void loadMetadata() throws Exception {
|
||||
mockSuccessfulMetadataGet(false);
|
||||
InitializrServiceMetadata metadata = this.invoker.loadMetadata("http://foo/bar");
|
||||
InitializrServiceMetadata metadata = this.invoker.loadMetadata("https://foo/bar");
|
||||
assertThat(metadata).isNotNull();
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -54,7 +54,7 @@ public class ProjectGenerationRequestTests {
|
||||
|
||||
@Test
|
||||
public void customServer() throws URISyntaxException {
|
||||
String customServerUrl = "http://foo:8080/initializr";
|
||||
String customServerUrl = "https://foo:8080/initializr";
|
||||
this.request.setServiceUrl(customServerUrl);
|
||||
this.request.getDependencies().add("security");
|
||||
assertThat(this.request.generateUrl(createDefaultMetadata())).isEqualTo(new URI(
|
||||
|
||||
Reference in New Issue
Block a user