URL Cleanup - Fix broken tests

See gh-22680
This commit is contained in:
Sam Brannen
2019-03-27 15:31:55 +01:00
parent 3db08c6b7a
commit 5dc9c4c527
21 changed files with 84 additions and 80 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -424,7 +424,7 @@ public class MvcUriComponentsBuilderTests {
this.request.setServerPort(9999);
this.request.setContextPath("/base");
assertEquals("https://example.org:9999/base/api/people/123/addresses",
assertEquals("http://example.org:9999/base/api/people/123/addresses",
fromController(PersonsAddressesController.class).buildAndExpand("123").toString());
}
@@ -437,7 +437,7 @@ public class MvcUriComponentsBuilderTests {
this.request.setServerPort(9999);
this.request.setContextPath("/base");
assertEquals("https://example.org:9999/base/api/people/123/addresses/DE",
assertEquals("http://example.org:9999/base/api/people/123/addresses/DE",
fromMethodCall(on(PersonsAddressesController.class).getAddressesForCountry("DE"))
.buildAndExpand("123").toString());
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2018 the original author or authors.
* Copyright 2002-2019 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.
@@ -111,7 +111,7 @@ public class AppCacheManifestTransformerTests {
containsString("/static/js/bar-bd508c62235b832d960298ca6c0b7645.js"));
assertThat("should not rewrite external resources", content, containsString("//example.org/style.css"));
assertThat("should not rewrite external resources", content, containsString("https://example.org/image.png"));
assertThat("should not rewrite external resources", content, containsString("http://example.org/image.png"));
assertThat("should generate fingerprint", content,
containsString("# Hash: 4bf0338bcbeb0a5b3a4ec9ed8864107d"));