From 179dd455da852a95072255c9f632d292989cf443 Mon Sep 17 00:00:00 2001 From: Ruslan Iushchenko Date: Fri, 31 May 2024 13:03:47 +0200 Subject: [PATCH] #415 Add type annotation since for some reason Scala fails to compile there. --- .../utils/httpclient/RetryableHttpClientSuite.scala | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pramen/extras/src/test/scala/za/co/absa/pramen/extras/utils/httpclient/RetryableHttpClientSuite.scala b/pramen/extras/src/test/scala/za/co/absa/pramen/extras/utils/httpclient/RetryableHttpClientSuite.scala index 1c5299f6..a01c3ea3 100644 --- a/pramen/extras/src/test/scala/za/co/absa/pramen/extras/utils/httpclient/RetryableHttpClientSuite.scala +++ b/pramen/extras/src/test/scala/za/co/absa/pramen/extras/utils/httpclient/RetryableHttpClientSuite.scala @@ -27,7 +27,7 @@ class RetryableHttpClientSuite extends AnyWordSpec { "execute" should { "return the response if the first attempt succeeds" in { val spy = new SimpleHttpClientSpy() - val client = new RetryableHttpClient(spy, 3, 1000) + val client: SimpleHttpClient = new RetryableHttpClient(spy, 3, 1000) val response = client.execute(request) @@ -38,7 +38,7 @@ class RetryableHttpClientSuite extends AnyWordSpec { "return the response if the first attempt fails, but next one succeeds" in { val spy = new SimpleHttpClientSpy(failNTimes = 1) - val client = new RetryableHttpClient(spy, 3, 1000) + val client: SimpleHttpClient = new RetryableHttpClient(spy, 3, 1000) val response = client.execute(request) @@ -49,7 +49,7 @@ class RetryableHttpClientSuite extends AnyWordSpec { "throw an exception if out of attempts" in { val spy = new SimpleHttpClientSpy(failNTimes = 3) - val client = new RetryableHttpClient(spy, 3, 1000) + val client: SimpleHttpClient = new RetryableHttpClient(spy, 3, 1000) val ex = intercept[RuntimeException] { client.execute(request) @@ -64,7 +64,7 @@ class RetryableHttpClientSuite extends AnyWordSpec { "close" should { "call super.close" in { val spy = new SimpleHttpClientSpy() - val client = new RetryableHttpClient(spy, 3, 1000) + val client: SimpleHttpClient = new RetryableHttpClient(spy, 3, 1000) client.close()