diff --git a/src/test/java/com/github/underscore/LodashTest.java b/src/test/java/com/github/underscore/LodashTest.java index 69cc2e09..46921b78 100644 --- a/src/test/java/com/github/underscore/LodashTest.java +++ b/src/test/java/com/github/underscore/LodashTest.java @@ -594,7 +594,8 @@ void selectTokensGetAllWriters() { void fetchGet() { U.FetchResponse result = U.fetch( - "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json"); + "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/" + + "main/src/test/resources/example.json"); result.json(); result.jsonMap(); assertEquals( @@ -607,7 +608,8 @@ void fetchGet() { assertEquals("Apple", U.get((Map) result.json(), "fruit")); U.Chain resultChain = U.chain( - "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json") + "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/" + + "main/src/test/resources/example.json") .fetch(); assertEquals( "{\n" @@ -626,7 +628,8 @@ void downloadUrl() throws IOException, URISyntaxException { try { long result = U.downloadUrl( - "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json", + "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/" + + "main/src/test/resources/example.json", "test.json"); assertEquals(65, result); } catch (javax.net.ssl.SSLHandshakeException ignored) { @@ -646,7 +649,8 @@ void decompressGzip() throws IOException { void fetchGetWithTimeouts() { U.FetchResponse result = U.fetch( - "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json", + "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/" + + "main/src/test/resources/example.json", 30000, 30000); assertEquals( @@ -706,7 +710,8 @@ void fetchGetHttps() { void fetchPut() { U.FetchResponse result = U.fetch( - "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json", + "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/" + + "main/src/test/resources/example.json", "PUT", "{" + " \"dragon\": {" @@ -719,7 +724,8 @@ void fetchPut() { assertEquals(403, result.getStatus()); U.FetchResponse result2 = U.fetch( - "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json", + "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/" + + "main/src/test/resources/example.json", "PUT", "{" + " \"dragon\": {" @@ -751,7 +757,7 @@ void fetchPut() { + "301 Moved Permanently\n" + "\n" + "

301 Moved Permanently

\n" - + "
cloudflare
\n" + + "
nginx
\n" + "\n" + "\n", resultChain.item().replace("\r\n", "\n"));