diff options
Diffstat (limited to 'clustercontroller-utils/src/test/java/com/yahoo/vespa/clustercontroller/utils/communication/http/AsyncHttpClientWithBaseTest.java')
-rw-r--r-- | clustercontroller-utils/src/test/java/com/yahoo/vespa/clustercontroller/utils/communication/http/AsyncHttpClientWithBaseTest.java | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/clustercontroller-utils/src/test/java/com/yahoo/vespa/clustercontroller/utils/communication/http/AsyncHttpClientWithBaseTest.java b/clustercontroller-utils/src/test/java/com/yahoo/vespa/clustercontroller/utils/communication/http/AsyncHttpClientWithBaseTest.java index e04eb1c043d..685ad492052 100644 --- a/clustercontroller-utils/src/test/java/com/yahoo/vespa/clustercontroller/utils/communication/http/AsyncHttpClientWithBaseTest.java +++ b/clustercontroller-utils/src/test/java/com/yahoo/vespa/clustercontroller/utils/communication/http/AsyncHttpClientWithBaseTest.java @@ -3,10 +3,15 @@ package com.yahoo.vespa.clustercontroller.utils.communication.http; import com.yahoo.vespa.clustercontroller.utils.communication.async.AsyncOperation; import com.yahoo.vespa.clustercontroller.utils.communication.async.AsyncOperationImpl; -import junit.framework.TestCase; +import org.junit.Test; -public class AsyncHttpClientWithBaseTest extends TestCase { +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotSame; +import static org.junit.Assert.assertTrue; +public class AsyncHttpClientWithBaseTest { + + @Test public void testOverride() { class HttpClient implements AsyncHttpClient<HttpResult> { HttpRequest lastRequest; @@ -39,11 +44,13 @@ public class AsyncHttpClientWithBaseTest extends TestCase { base.close(); } + @Test public void testClientMustBeSet() { - try{ - new AsyncHttpClientWithBase<HttpResult>(null); + try { + new AsyncHttpClientWithBase<>(null); assertTrue(false); } catch (IllegalArgumentException e) { } } + } |