55
55
56
56
public class BasicHttpTest extends AbstractBasicTest {
57
57
58
- @ Test (groups = { "standalone" , "async" } )
58
+ @ Test (groups = "standalone" )
59
59
public void asyncProviderEncodingTest () throws Exception {
60
60
try (AsyncHttpClient client = asyncHttpClient ()) {
61
61
Request request = get (getTargetUrl () + "?q=+%20x" ).build ();
@@ -78,7 +78,7 @@ public void onThrowable(Throwable t) {
78
78
}
79
79
}
80
80
81
- @ Test (groups = { "standalone" , "async" } )
81
+ @ Test (groups = "standalone" )
82
82
public void asyncProviderEncodingTest2 () throws Exception {
83
83
try (AsyncHttpClient client = asyncHttpClient ()) {
84
84
Request request = get (getTargetUrl () + "" ).addQueryParam ("q" , "a b" ).build ();
@@ -100,7 +100,7 @@ public void onThrowable(Throwable t) {
100
100
}
101
101
}
102
102
103
- @ Test (groups = { "standalone" , "async" } )
103
+ @ Test (groups = "standalone" )
104
104
public void emptyRequestURI () throws Exception {
105
105
try (AsyncHttpClient client = asyncHttpClient ()) {
106
106
Request request = get (getTargetUrl ()).build ();
@@ -122,7 +122,7 @@ public void onThrowable(Throwable t) {
122
122
}
123
123
}
124
124
125
- @ Test (groups = { "standalone" , "async" } )
125
+ @ Test (groups = "standalone" )
126
126
public void asyncProviderContentLenghtGETTest () throws Exception {
127
127
final HttpURLConnection connection = (HttpURLConnection ) new URL (getTargetUrl ()).openConnection ();
128
128
connection .connect ();
@@ -166,7 +166,7 @@ public void onThrowable(Throwable t) {
166
166
}
167
167
}
168
168
169
- @ Test (groups = { "standalone" , "async" } )
169
+ @ Test (groups = "standalone" )
170
170
public void asyncContentTypeGETTest () throws Exception {
171
171
try (AsyncHttpClient client = asyncHttpClient ()) {
172
172
final CountDownLatch l = new CountDownLatch (1 );
@@ -190,7 +190,7 @@ public Response onCompleted(Response response) throws Exception {
190
190
}
191
191
}
192
192
193
- @ Test (groups = { "standalone" , "async" } )
193
+ @ Test (groups = "standalone" )
194
194
public void asyncHeaderGETTest () throws Exception {
195
195
try (AsyncHttpClient client = asyncHttpClient ()) {
196
196
final CountDownLatch l = new CountDownLatch (1 );
@@ -215,7 +215,7 @@ public Response onCompleted(Response response) throws Exception {
215
215
}
216
216
}
217
217
218
- @ Test (groups = { "standalone" , "async" } )
218
+ @ Test (groups = "standalone" )
219
219
public void asyncHeaderPOSTTest () throws Exception {
220
220
try (AsyncHttpClient client = asyncHttpClient ()) {
221
221
final CountDownLatch l = new CountDownLatch (1 );
@@ -249,7 +249,7 @@ public Response onCompleted(Response response) throws Exception {
249
249
}
250
250
}
251
251
252
- @ Test (groups = { "standalone" , "async" } )
252
+ @ Test (groups = "standalone" )
253
253
public void asyncParamPOSTTest () throws Exception {
254
254
try (AsyncHttpClient client = asyncHttpClient ()) {
255
255
final CountDownLatch l = new CountDownLatch (1 );
@@ -283,7 +283,7 @@ public Response onCompleted(Response response) throws Exception {
283
283
}
284
284
}
285
285
286
- @ Test (groups = { "standalone" , "async" } )
286
+ @ Test (groups = "standalone" )
287
287
public void asyncStatusHEADTest () throws Exception {
288
288
try (AsyncHttpClient client = asyncHttpClient ()) {
289
289
final CountDownLatch l = new CountDownLatch (1 );
@@ -315,7 +315,7 @@ public Response onCompleted(Response response) throws Exception {
315
315
}
316
316
317
317
// TODO: fix test
318
- @ Test (groups = { "standalone" , "async" } , enabled = false )
318
+ @ Test (groups = "standalone" , enabled = false )
319
319
public void asyncStatusHEADContentLenghtTest () throws Exception {
320
320
try (AsyncHttpClient client = asyncHttpClient (config ().setRequestTimeout (120 * 1000 ))) {
321
321
final CountDownLatch l = new CountDownLatch (1 );
@@ -353,7 +353,7 @@ public void asyncNullSchemeTest() throws Exception {
353
353
}
354
354
}
355
355
356
- @ Test (groups = { "standalone" , "async" } )
356
+ @ Test (groups = "standalone" )
357
357
public void asyncDoGetTransferEncodingTest () throws Exception {
358
358
try (AsyncHttpClient client = asyncHttpClient ()) {
359
359
final CountDownLatch l = new CountDownLatch (1 );
@@ -378,7 +378,7 @@ public Response onCompleted(Response response) throws Exception {
378
378
}
379
379
}
380
380
381
- @ Test (groups = { "standalone" , "async" } )
381
+ @ Test (groups = "standalone" )
382
382
public void asyncDoGetHeadersTest () throws Exception {
383
383
try (AsyncHttpClient client = asyncHttpClient ()) {
384
384
final CountDownLatch l = new CountDownLatch (1 );
@@ -409,7 +409,7 @@ public Response onCompleted(Response response) throws Exception {
409
409
}
410
410
}
411
411
412
- @ Test (groups = { "standalone" , "async" } )
412
+ @ Test (groups = "standalone" )
413
413
public void asyncDoGetCookieTest () throws Exception {
414
414
try (AsyncHttpClient client = asyncHttpClient ()) {
415
415
final CountDownLatch l = new CountDownLatch (1 );
@@ -443,7 +443,7 @@ public Response onCompleted(Response response) throws Exception {
443
443
}
444
444
}
445
445
446
- @ Test (groups = { "standalone" , "async" } )
446
+ @ Test (groups = "standalone" )
447
447
public void asyncDoPostDefaultContentType () throws Exception {
448
448
try (AsyncHttpClient client = asyncHttpClient ()) {
449
449
final CountDownLatch l = new CountDownLatch (1 );
@@ -468,15 +468,15 @@ public Response onCompleted(Response response) throws Exception {
468
468
}
469
469
}
470
470
471
- @ Test (groups = { "standalone" , "async" } )
471
+ @ Test (groups = "standalone" )
472
472
public void asyncDoPostBodyIsoTest () throws Exception {
473
473
try (AsyncHttpClient client = asyncHttpClient ()) {
474
474
Response response = client .preparePost (getTargetUrl ()).addHeader ("X-ISO" , "true" ).setBody ("\u017D \u017D \u017D \u017D \u017D \u017D " ).execute ().get ();
475
475
assertEquals (response .getResponseBody ().getBytes ("ISO-8859-1" ), "\u017D \u017D \u017D \u017D \u017D \u017D " .getBytes ("ISO-8859-1" ));
476
476
}
477
477
}
478
478
479
- @ Test (groups = { "standalone" , "async" } )
479
+ @ Test (groups = "standalone" )
480
480
public void asyncDoPostBytesTest () throws Exception {
481
481
try (AsyncHttpClient client = asyncHttpClient ()) {
482
482
final CountDownLatch l = new CountDownLatch (1 );
@@ -512,7 +512,7 @@ public Response onCompleted(Response response) throws Exception {
512
512
}
513
513
}
514
514
515
- @ Test (groups = { "standalone" , "async" } )
515
+ @ Test (groups = "standalone" )
516
516
public void asyncDoPostInputStreamTest () throws Exception {
517
517
try (AsyncHttpClient client = asyncHttpClient ()) {
518
518
final CountDownLatch l = new CountDownLatch (1 );
@@ -548,7 +548,7 @@ public Response onCompleted(Response response) throws Exception {
548
548
}
549
549
}
550
550
551
- @ Test (groups = { "standalone" , "async" } )
551
+ @ Test (groups = "standalone" )
552
552
public void asyncDoPutInputStreamTest () throws Exception {
553
553
try (AsyncHttpClient client = asyncHttpClient ()) {
554
554
final CountDownLatch l = new CountDownLatch (1 );
@@ -582,7 +582,7 @@ public Response onCompleted(Response response) throws Exception {
582
582
}
583
583
}
584
584
585
- @ Test (groups = { "standalone" , "async" } )
585
+ @ Test (groups = "standalone" )
586
586
public void asyncDoPostMultiPartTest () throws Exception {
587
587
try (AsyncHttpClient client = asyncHttpClient ()) {
588
588
final CountDownLatch l = new CountDownLatch (1 );
@@ -610,7 +610,7 @@ public Response onCompleted(Response response) throws Exception {
610
610
}
611
611
}
612
612
613
- @ Test (groups = { "standalone" , "async" } )
613
+ @ Test (groups = "standalone" )
614
614
public void asyncDoPostBasicGZIPTest () throws Exception {
615
615
try (AsyncHttpClient client = asyncHttpClient (config ().setCompressionEnforced (true ))) {
616
616
final CountDownLatch l = new CountDownLatch (1 );
@@ -642,7 +642,7 @@ public Response onCompleted(Response response) throws Exception {
642
642
}
643
643
}
644
644
645
- @ Test (groups = { "standalone" , "async" } )
645
+ @ Test (groups = "standalone" )
646
646
public void asyncDoPostProxyTest () throws Exception {
647
647
try (AsyncHttpClient client = asyncHttpClient (config ().setProxyServer (proxyServer ("127.0.0.1" , port2 ).build ()))) {
648
648
HttpHeaders h = new DefaultHttpHeaders ();
@@ -669,7 +669,7 @@ public void onThrowable(Throwable t) {
669
669
}
670
670
}
671
671
672
- @ Test (groups = { "standalone" , "async" } )
672
+ @ Test (groups = "standalone" )
673
673
public void asyncRequestVirtualServerPOSTTest () throws Exception {
674
674
try (AsyncHttpClient client = asyncHttpClient ()) {
675
675
HttpHeaders h = new DefaultHttpHeaders ();
@@ -692,7 +692,7 @@ public void asyncRequestVirtualServerPOSTTest() throws Exception {
692
692
}
693
693
}
694
694
695
- @ Test (groups = { "standalone" , "async" } )
695
+ @ Test (groups = "standalone" )
696
696
public void asyncDoPutTest () throws Exception {
697
697
try (AsyncHttpClient client = asyncHttpClient ()) {
698
698
HttpHeaders h = new DefaultHttpHeaders ();
@@ -709,7 +709,7 @@ public void asyncDoPutTest() throws Exception {
709
709
}
710
710
}
711
711
712
- @ Test (groups = { "standalone" , "async" } )
712
+ @ Test (groups = "standalone" )
713
713
public void asyncDoPostLatchBytesTest () throws Exception {
714
714
try (AsyncHttpClient c = asyncHttpClient ()) {
715
715
final CountDownLatch l = new CountDownLatch (1 );
@@ -743,7 +743,7 @@ public Response onCompleted(Response response) throws Exception {
743
743
}
744
744
}
745
745
746
- @ Test (groups = { "standalone" , "async" } , expectedExceptions = { CancellationException .class })
746
+ @ Test (groups = "standalone" , expectedExceptions = { CancellationException .class })
747
747
public void asyncDoPostDelayCancelTest () throws Exception {
748
748
try (AsyncHttpClient client = asyncHttpClient ()) {
749
749
HttpHeaders h = new DefaultHttpHeaders ();
@@ -762,7 +762,7 @@ public void onThrowable(Throwable t) {
762
762
}
763
763
}
764
764
765
- @ Test (groups = { "standalone" , "async" } )
765
+ @ Test (groups = "standalone" )
766
766
public void asyncDoPostDelayBytesTest () throws Exception {
767
767
try (AsyncHttpClient client = asyncHttpClient ()) {
768
768
HttpHeaders h = new DefaultHttpHeaders ();
@@ -792,7 +792,7 @@ public void onThrowable(Throwable t) {
792
792
}
793
793
}
794
794
795
- @ Test (groups = { "standalone" , "async" } )
795
+ @ Test (groups = "standalone" )
796
796
public void asyncDoPostNullBytesTest () throws Exception {
797
797
try (AsyncHttpClient client = asyncHttpClient ()) {
798
798
HttpHeaders h = new DefaultHttpHeaders ();
@@ -811,7 +811,7 @@ public void asyncDoPostNullBytesTest() throws Exception {
811
811
}
812
812
}
813
813
814
- @ Test (groups = { "standalone" , "async" } )
814
+ @ Test (groups = "standalone" )
815
815
public void asyncDoPostListenerBytesTest () throws Exception {
816
816
try (AsyncHttpClient client = asyncHttpClient ()) {
817
817
HttpHeaders h = new DefaultHttpHeaders ();
@@ -842,7 +842,7 @@ public Response onCompleted(Response response) throws Exception {
842
842
}
843
843
}
844
844
845
- @ Test (groups = { "standalone" , "async" } )
845
+ @ Test (groups = "standalone" )
846
846
public void asyncConnectInvalidFuture () throws Exception {
847
847
try (AsyncHttpClient client = asyncHttpClient ()) {
848
848
int dummyPort = findFreePort ();
@@ -867,7 +867,7 @@ public void onThrowable(Throwable t) {
867
867
}
868
868
}
869
869
870
- @ Test (groups = { "standalone" , "async" } )
870
+ @ Test (groups = "standalone" )
871
871
public void asyncConnectInvalidPortFuture () throws Exception {
872
872
try (AsyncHttpClient client = asyncHttpClient ()) {
873
873
int dummyPort = findFreePort ();
@@ -888,7 +888,7 @@ public void onThrowable(Throwable t) {
888
888
}
889
889
}
890
890
891
- @ Test (groups = { "standalone" , "async" } )
891
+ @ Test (groups = "standalone" )
892
892
public void asyncConnectInvalidPort () throws Exception {
893
893
try (AsyncHttpClient client = asyncHttpClient ()) {
894
894
// pick a random unused local port
@@ -908,7 +908,7 @@ public void onThrowable(Throwable t) {
908
908
}
909
909
}
910
910
911
- @ Test (groups = { "standalone" , "async" } )
911
+ @ Test (groups = "standalone" )
912
912
public void asyncConnectInvalidHandlerPort () throws Exception {
913
913
try (AsyncHttpClient client = asyncHttpClient ()) {
914
914
final CountDownLatch l = new CountDownLatch (1 );
@@ -955,7 +955,7 @@ public void onThrowable(Throwable t) {
955
955
}
956
956
}
957
957
958
- @ Test (groups = { "standalone" , "async" } )
958
+ @ Test (groups = "standalone" )
959
959
public void asyncConnectInvalidFuturePort () throws Exception {
960
960
try (AsyncHttpClient client = asyncHttpClient ()) {
961
961
final AtomicBoolean called = new AtomicBoolean (false );
@@ -982,7 +982,7 @@ public void onThrowable(Throwable t) {
982
982
}
983
983
}
984
984
985
- @ Test (groups = { "standalone" , "async" } )
985
+ @ Test (groups = "standalone" )
986
986
public void asyncContentLenghtGETTest () throws Exception {
987
987
try (AsyncHttpClient client = asyncHttpClient ()) {
988
988
Response response = client .prepareGet (getTargetUrl ()).execute (new AsyncCompletionHandlerAdapter () {
@@ -998,7 +998,7 @@ public void onThrowable(Throwable t) {
998
998
}
999
999
}
1000
1000
1001
- @ Test (groups = { "standalone" , "async" } )
1001
+ @ Test (groups = "standalone" )
1002
1002
public void asyncResponseEmptyBody () throws Exception {
1003
1003
try (AsyncHttpClient client = asyncHttpClient ()) {
1004
1004
Response response = client .prepareGet (getTargetUrl ()).execute (new AsyncCompletionHandlerAdapter () {
@@ -1072,7 +1072,7 @@ public void onThrowable(Throwable t) {
1072
1072
}
1073
1073
}
1074
1074
1075
- @ Test (groups = { "standalone" , "async" } )
1075
+ @ Test (groups = "standalone" )
1076
1076
public void asyncDoGetDelayHandlerTest () throws Exception {
1077
1077
try (AsyncHttpClient client = asyncHttpClient (config ().setRequestTimeout (5 * 1000 ))) {
1078
1078
HttpHeaders h = new DefaultHttpHeaders ();
@@ -1113,7 +1113,7 @@ public void onThrowable(Throwable t) {
1113
1113
}
1114
1114
}
1115
1115
1116
- @ Test (groups = { "standalone" , "async" } )
1116
+ @ Test (groups = "standalone" )
1117
1117
public void asyncDoGetQueryStringTest () throws Exception {
1118
1118
try (AsyncHttpClient client = asyncHttpClient ()) {
1119
1119
// Use a l in case the assert fail
@@ -1143,7 +1143,7 @@ public Response onCompleted(Response response) throws Exception {
1143
1143
}
1144
1144
}
1145
1145
1146
- @ Test (groups = { "standalone" , "async" } )
1146
+ @ Test (groups = "standalone" )
1147
1147
public void asyncDoGetKeepAliveHandlerTest () throws Exception {
1148
1148
try (AsyncHttpClient client = asyncHttpClient ()) {
1149
1149
// Use a l in case the assert fail
@@ -1322,7 +1322,7 @@ public void idleRequestTimeoutTest() throws Exception {
1322
1322
}
1323
1323
}
1324
1324
1325
- @ Test (groups = { "standalone" , "async" } )
1325
+ @ Test (groups = "standalone" )
1326
1326
public void asyncDoPostCancelTest () throws Exception {
1327
1327
try (AsyncHttpClient client = asyncHttpClient ()) {
1328
1328
HttpHeaders h = new DefaultHttpHeaders ();
@@ -1386,7 +1386,7 @@ public void mirrorByteTest() throws Exception {
1386
1386
}
1387
1387
}
1388
1388
1389
- @ Test (groups = { "standalone" , "async" } )
1389
+ @ Test (groups = "standalone" )
1390
1390
public void testNewConnectionEventsFired () throws Exception {
1391
1391
Request request = get ("http://127.0.0.1:" + port1 + "/Test" ).build ();
1392
1392
0 commit comments