Skip to content

Commit

Permalink
refactor (organize import and quality issues) after resolving conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
FBibonne committed Feb 2, 2025
1 parent f673745 commit da3e37c
Showing 1 changed file with 11 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,9 @@
*/
package org.springframework.batch.core.job.builder;

import java.util.Arrays;

import javax.sql.DataSource;

import static org.junit.jupiter.api.Assertions.assertEquals;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.springframework.batch.core.*;
Expand All @@ -40,6 +37,9 @@
import org.springframework.batch.core.step.StepSupport;
import org.springframework.batch.core.step.builder.StepBuilder;
import org.springframework.batch.item.support.ListItemReader;
import org.springframework.batch.repeat.RepeatStatus;
import org.springframework.batch.support.transaction.ResourcelessTransactionManager;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;
Expand All @@ -54,13 +54,15 @@

import javax.sql.DataSource;
import java.util.Arrays;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;

import static org.junit.Assert.assertTrue;
import static org.junit.jupiter.api.Assertions.assertEquals;

/**
* @author Dave Syer
* @author Mahmoud Ben Hassine
* @author Fabrice Bibonne
*/
class FlowJobBuilderTests {

Expand Down Expand Up @@ -374,7 +376,7 @@ void testStepNamesMustBeUniqueWithinFlowDefinition() throws JobInstanceAlreadyCo
new JobParametersBuilder().addLong("random", 2L)
.addString("stepTwo.name", JobConfigurationForStepNameUnique.SHARED_NAME)
.toJobParameters());
assertTrue(jobExecution.getAllFailureExceptions()
Assertions.assertTrue(jobExecution.getAllFailureExceptions()
.stream()
.map(Object::getClass)
.anyMatch(AlreadyUsedStepNameException.class::equals));
Expand All @@ -383,7 +385,7 @@ void testStepNamesMustBeUniqueWithinFlowDefinition() throws JobInstanceAlreadyCo
new JobParametersBuilder().addLong("random", 1L)
.addString("stepTwo.name", JobConfigurationForStepNameUnique.SHARED_NAME)
.toJobParameters());
assertTrue(jobExecution.getAllFailureExceptions()
Assertions.assertTrue(jobExecution.getAllFailureExceptions()
.stream()
.map(Object::getClass)
.anyMatch(AlreadyUsedStepNameException.class::equals));
Expand Down

0 comments on commit da3e37c

Please sign in to comment.