@@ -594,7 +594,8 @@ void selectTokensGetAllWriters() {
594
594
void fetchGet () {
595
595
U .FetchResponse result =
596
596
U .fetch (
597
- "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json" );
597
+ "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/"
598
+ + "main/src/test/resources/example.json" );
598
599
result .json ();
599
600
result .jsonMap ();
600
601
assertEquals (
@@ -607,7 +608,8 @@ void fetchGet() {
607
608
assertEquals ("Apple" , U .get ((Map <String , Object >) result .json (), "fruit" ));
608
609
U .Chain <?> resultChain =
609
610
U .chain (
610
- "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json" )
611
+ "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/"
612
+ + "main/src/test/resources/example.json" )
611
613
.fetch ();
612
614
assertEquals (
613
615
"{\n "
@@ -626,7 +628,8 @@ void downloadUrl() throws IOException, URISyntaxException {
626
628
try {
627
629
long result =
628
630
U .downloadUrl (
629
- "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json" ,
631
+ "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/"
632
+ + "main/src/test/resources/example.json" ,
630
633
"test.json" );
631
634
assertEquals (65 , result );
632
635
} catch (javax .net .ssl .SSLHandshakeException ignored ) {
@@ -646,7 +649,8 @@ void decompressGzip() throws IOException {
646
649
void fetchGetWithTimeouts () {
647
650
U .FetchResponse result =
648
651
U .fetch (
649
- "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json" ,
652
+ "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/"
653
+ + "main/src/test/resources/example.json" ,
650
654
30000 ,
651
655
30000 );
652
656
assertEquals (
@@ -706,7 +710,8 @@ void fetchGetHttps() {
706
710
void fetchPut () {
707
711
U .FetchResponse result =
708
712
U .fetch (
709
- "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json" ,
713
+ "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/"
714
+ + "main/src/test/resources/example.json" ,
710
715
"PUT" ,
711
716
"{"
712
717
+ " \" dragon\" : {"
@@ -719,7 +724,8 @@ void fetchPut() {
719
724
assertEquals (403 , result .getStatus ());
720
725
U .FetchResponse result2 =
721
726
U .fetch (
722
- "https://support.oneskyapp.com/hc/en-us/article_attachments/202761627/example_1.json" ,
727
+ "https://raw.githubusercontent.com/javadev/underscore-java/refs/heads/"
728
+ + "main/src/test/resources/example.json" ,
723
729
"PUT" ,
724
730
"{"
725
731
+ " \" dragon\" : {"
@@ -751,7 +757,7 @@ void fetchPut() {
751
757
+ "<head><title>301 Moved Permanently</title></head>\n "
752
758
+ "<body>\n "
753
759
+ "<center><h1>301 Moved Permanently</h1></center>\n "
754
- + "<hr><center>cloudflare </center>\n "
760
+ + "<hr><center>nginx </center>\n "
755
761
+ "</body>\n "
756
762
+ "</html>\n " ,
757
763
resultChain .item ().replace ("\r \n " , "\n " ));
0 commit comments