From b56909740210ce45469c901d26326f092ffdd7e8 Mon Sep 17 00:00:00 2001 From: Patrik Nordwall Date: Tue, 17 Oct 2023 17:23:57 +0200 Subject: [PATCH] test: UNKNOWN or UNAVAILABLE (#1860) --- .../akka/grpc/scaladsl/LoadBalancingIntegrationSpec.scala | 4 ++-- .../akka/grpc/scaladsl/NonBalancingIntegrationSpec.scala | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/interop-tests/src/test/scala/akka/grpc/scaladsl/LoadBalancingIntegrationSpec.scala b/interop-tests/src/test/scala/akka/grpc/scaladsl/LoadBalancingIntegrationSpec.scala index 205715d56..0bd22d5eb 100644 --- a/interop-tests/src/test/scala/akka/grpc/scaladsl/LoadBalancingIntegrationSpec.scala +++ b/interop-tests/src/test/scala/akka/grpc/scaladsl/LoadBalancingIntegrationSpec.scala @@ -154,7 +154,7 @@ class LoadBalancingIntegrationSpec(backend: String, config: Config = ConfigFacto client.sayHello(HelloRequest(s"Hello friend")).failed.futureValue.asInstanceOf[StatusRuntimeException] // FIXME issue #1857, not sure how this is supposed to be if (backend == "netty") - failure.getStatus.getCode should be(Code.UNKNOWN) + failure.getStatus.getCode should (equal(Code.UNKNOWN).or(equal(Code.UNAVAILABLE))) else failure.getStatus.getCode should be(Code.UNAVAILABLE) @@ -177,7 +177,7 @@ class LoadBalancingIntegrationSpec(backend: String, config: Config = ConfigFacto client.sayHello(HelloRequest(s"Hello friend")).failed.futureValue.asInstanceOf[StatusRuntimeException] // FIXME issue #1857, not sure how this is supposed to be if (backend == "netty") - failure.getStatus.getCode should be(Code.UNKNOWN) + failure.getStatus.getCode should (equal(Code.UNKNOWN).or(equal(Code.UNAVAILABLE))) else failure.getStatus.getCode should be(Code.UNAVAILABLE) diff --git a/interop-tests/src/test/scala/akka/grpc/scaladsl/NonBalancingIntegrationSpec.scala b/interop-tests/src/test/scala/akka/grpc/scaladsl/NonBalancingIntegrationSpec.scala index 55d07413c..219f17c8c 100644 --- a/interop-tests/src/test/scala/akka/grpc/scaladsl/NonBalancingIntegrationSpec.scala +++ b/interop-tests/src/test/scala/akka/grpc/scaladsl/NonBalancingIntegrationSpec.scala @@ -177,7 +177,7 @@ class NonBalancingIntegrationSpec(backend: String) client.sayHello(HelloRequest(s"Hello friend")).failed.futureValue.asInstanceOf[StatusRuntimeException] // FIXME issue #1857, not sure how this is supposed to be if (backend == "netty") - failure.getStatus.getCode should be(Code.UNKNOWN) + failure.getStatus.getCode should (equal(Code.UNKNOWN).or(equal(Code.UNAVAILABLE))) else { failure.getStatus.getCode should be(Code.UNAVAILABLE) client.closed.failed.futureValue shouldBe a[ClientConnectionException]