Skip to content

Commit

Permalink
JBERET-445: Static import assertions
Browse files Browse the repository at this point in the history
  • Loading branch information
DaScheid authored and liweinan committed Feb 11, 2024
1 parent e125ec3 commit d417d53
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import org.junit.jupiter.api.Test;

import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.junit.jupiter.api.Assertions.fail;

public class PurgeMongoRepositoryIT extends PurgeRepositoryTestBase {
static final String purgeMongoRepositoryJobName = "purgeMongoRepository";
Expand Down Expand Up @@ -209,13 +210,13 @@ public void removeStepExecutionsAndJobExecutionsAndJobInstances() throws Excepti

try {
final JobInstance ins = jobOperator.getJobInstance(prepurge1JobExecutionId);
org.junit.Assertions.fail("Expecting NoSuchJobExecutionException, but got " + ins);
fail("Expecting NoSuchJobExecutionException, but got " + ins);
} catch (final NoSuchJobExecutionException e) {
System.out.printf("Got expected %s%n", e);
}
try {
final JobInstance ins = jobOperator.getJobInstance(prepurge2JobExecutionId);
org.junit.Assertions.fail("Expecting NoSuchJobException, but got " + ins);
fail("Expecting NoSuchJobException, but got " + ins);
} catch (final NoSuchJobExecutionException e) {
System.out.printf("Got expected %s%n", e);
}
Expand Down Expand Up @@ -244,13 +245,13 @@ public void removeAll() throws Exception {

try {
final int count = jobOperator.getJobInstanceCount(prepurgeJobName);
org.junit.Assertions.fail("Expecting NoSuchJobException, but got " + count);
fail("Expecting NoSuchJobException, but got " + count);
} catch (final NoSuchJobException e) {
System.out.printf("Got expected %s%n", e);
}
try {
final int count = jobOperator.getJobInstanceCount(prepurge2JobName);
org.junit.Assertions.fail("Expecting NoSuchJobException, but got " + count);
fail("Expecting NoSuchJobException, but got " + count);
} catch (final NoSuchJobException e) {
System.out.printf("Got expected %s%n", e);
}
Expand Down

0 comments on commit d417d53

Please sign in to comment.