Skip to content

Commit 36710f9

Browse files
committed
assertions
Signed-off-by: wind57 <[email protected]>
1 parent 65b7011 commit 36710f9

File tree

1 file changed

+3
-3
lines changed
  • spring-cloud-kubernetes-test-support/src/main/java/org/springframework/cloud/kubernetes/integration/tests/commons/native_client

1 file changed

+3
-3
lines changed

spring-cloud-kubernetes-test-support/src/main/java/org/springframework/cloud/kubernetes/integration/tests/commons/native_client/Util.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,13 +53,13 @@
5353
import jakarta.annotation.Nullable;
5454
import org.apache.commons.logging.Log;
5555
import org.apache.commons.logging.LogFactory;
56+
import org.assertj.core.api.Assertions;
5657
import org.testcontainers.k3s.K3sContainer;
5758

5859
import org.springframework.cloud.kubernetes.integration.tests.commons.Images;
5960
import org.springframework.cloud.kubernetes.integration.tests.commons.Phase;
6061

6162
import static org.awaitility.Awaitility.await;
62-
import static org.junit.jupiter.api.Assertions.fail;
6363
import static org.springframework.cloud.kubernetes.integration.tests.commons.Commons.loadImage;
6464
import static org.springframework.cloud.kubernetes.integration.tests.commons.Commons.pomVersion;
6565
import static org.springframework.cloud.kubernetes.integration.tests.commons.Commons.pullImage;
@@ -548,7 +548,7 @@ private boolean isDeploymentReady(String deploymentName, String namespace) throw
548548
V1DeploymentList deployments = appsV1Api.listNamespacedDeployment(namespace, null, null, null,
549549
"metadata.name=" + deploymentName, null, null, null, null, null, null, null);
550550
if (deployments.getItems().isEmpty()) {
551-
fail("No deployments with the name " + deploymentName);
551+
Assertions.fail("No deployments with the name " + deploymentName);
552552
}
553553
V1Deployment deployment = deployments.getItems().get(0);
554554
if (deployment.getStatus() != null) {
@@ -580,7 +580,7 @@ private static boolean isDeploymentReadyAfterPatch(String deploymentName, String
580580
V1DeploymentList deployments = new AppsV1Api().listNamespacedDeployment(namespace, null, null, null,
581581
"metadata.name=" + deploymentName, null, null, null, null, null, null, null);
582582
if (deployments.getItems().isEmpty()) {
583-
fail("No deployment with name " + deploymentName);
583+
Assertions.fail("No deployment with name " + deploymentName);
584584
}
585585

586586
V1Deployment deployment = deployments.getItems().get(0);

0 commit comments

Comments
 (0)