Replace usage of "build" directory with "target"
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# Placeholders batch.*
|
||||
# for H2:
|
||||
batch.jdbc.driver=org.h2.Driver
|
||||
batch.jdbc.url=jdbc:h2:file:build/data/h2
|
||||
batch.jdbc.url=jdbc:h2:file:target/data/h2
|
||||
batch.jdbc.user=sa
|
||||
batch.jdbc.password=
|
||||
batch.database.incrementer.class=org.springframework.jdbc.support.incrementer.H2SequenceMaxValueIncrementer
|
||||
|
||||
@@ -24,7 +24,7 @@ import org.springframework.beans.factory.config.AbstractFactoryBean;
|
||||
|
||||
public class DerbyDataSourceFactoryBean extends AbstractFactoryBean<DataSource> {
|
||||
|
||||
private String dataDirectory = "build/derby-home";
|
||||
private String dataDirectory = "target/derby-home";
|
||||
|
||||
public void setDataDirectory(String dataDirectory) {
|
||||
this.dataDirectory = dataDirectory;
|
||||
@@ -38,7 +38,7 @@ public class DerbyDataSourceFactoryBean extends AbstractFactoryBean<DataSource>
|
||||
System.setProperty("derby.storage.pageCacheSize", "100");
|
||||
|
||||
final EmbeddedDataSource ds = new EmbeddedDataSource();
|
||||
ds.setDatabaseName("build/derbydb");
|
||||
ds.setDatabaseName("target/derbydb");
|
||||
ds.setCreateDatabase("create");
|
||||
|
||||
return ds;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Placeholders batch.*
|
||||
# for Derby:
|
||||
batch.jdbc.driver=org.apache.derby.jdbc.EmbeddedDriver
|
||||
batch.jdbc.url=jdbc:derby:build/derby-home/test;create=true
|
||||
batch.jdbc.url=jdbc:derby:target/derby-home/test;create=true
|
||||
batch.jdbc.user=sa
|
||||
batch.jdbc.password=
|
||||
batch.jdbc.testWhileIdle=false
|
||||
|
||||
@@ -208,7 +208,7 @@ public class StoredProcedureItemReaderBuilderTests {
|
||||
public DerbyDataSourceFactoryBean dataSource() {
|
||||
DerbyDataSourceFactoryBean derbyDataSourceFactoryBean = new DerbyDataSourceFactoryBean();
|
||||
|
||||
derbyDataSourceFactoryBean.setDataDirectory("build/derby-home");
|
||||
derbyDataSourceFactoryBean.setDataDirectory("target/derby-home");
|
||||
|
||||
return derbyDataSourceFactoryBean;
|
||||
}
|
||||
|
||||
@@ -398,7 +398,7 @@ public class FlatFileItemReaderTests {
|
||||
@Test
|
||||
public void testDirectoryResource() throws Exception {
|
||||
|
||||
FileSystemResource resource = new FileSystemResource("build/data");
|
||||
FileSystemResource resource = new FileSystemResource("target/data");
|
||||
resource.getFile().mkdirs();
|
||||
assertTrue(resource.getFile().isDirectory());
|
||||
reader.setResource(resource);
|
||||
|
||||
@@ -527,7 +527,7 @@ public class FlatFileItemWriterTests {
|
||||
public void testOpenWithNonWritableFile() throws Exception {
|
||||
writer = new FlatFileItemWriter<>();
|
||||
writer.setLineAggregator(new PassThroughLineAggregator<>());
|
||||
FileSystemResource file = new FileSystemResource("build/no-such-file.foo");
|
||||
FileSystemResource file = new FileSystemResource("target/no-such-file.foo");
|
||||
writer.setResource(file);
|
||||
new File(file.getFile().getParent()).mkdirs();
|
||||
file.getFile().createNewFile();
|
||||
@@ -838,7 +838,7 @@ public class FlatFileItemWriterTests {
|
||||
* If append=true a new output file should still be created on the first run (not restart).
|
||||
*/
|
||||
public void testAppendToNotYetExistingFile() throws Exception {
|
||||
Resource toBeCreated = new FileSystemResource("build/FlatFileItemWriterTests.out");
|
||||
Resource toBeCreated = new FileSystemResource("target/FlatFileItemWriterTests.out");
|
||||
|
||||
outputFile = toBeCreated.getFile(); //enable easy content reading and auto-delete the file
|
||||
|
||||
|
||||
@@ -318,7 +318,7 @@ public class MultiResourceItemReaderIntegrationTests {
|
||||
*/
|
||||
@Test
|
||||
public void testDirectoryResources() throws Exception {
|
||||
FileSystemResource resource = new FileSystemResource("build/data");
|
||||
FileSystemResource resource = new FileSystemResource("target/data");
|
||||
resource.getFile().mkdirs();
|
||||
assertTrue(resource.getFile().isDirectory());
|
||||
tested.setResources(new Resource[] { resource });
|
||||
|
||||
@@ -70,7 +70,7 @@ public abstract class JsonFileItemWriterFunctionalTests {
|
||||
|
||||
@Before
|
||||
public void setUp() throws Exception {
|
||||
Path outputFilePath = Paths.get("build", "trades.json");
|
||||
Path outputFilePath = Paths.get("target", "trades.json");
|
||||
Files.deleteIfExists(outputFilePath);
|
||||
this.resource = new FileSystemResource(outputFilePath.toFile());
|
||||
this.executionContext = new ExecutionContext();
|
||||
@@ -283,7 +283,7 @@ public abstract class JsonFileItemWriterFunctionalTests {
|
||||
* If append=true a new output file should still be created on the first run (not restart).
|
||||
*/
|
||||
public void testAppendToNotYetExistingFile() throws Exception {
|
||||
Resource toBeCreated = new FileSystemResource("build/FlatFileItemWriterTests.out");
|
||||
Resource toBeCreated = new FileSystemResource("target/FlatFileItemWriterTests.out");
|
||||
|
||||
File outputFile = toBeCreated.getFile(); //enable easy content reading and auto-delete the file
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ import static org.junit.Assert.fail;
|
||||
*/
|
||||
public class FileUtilsTests {
|
||||
|
||||
private File file = new File("build/FileUtilsTests.tmp");
|
||||
private File file = new File("target/FileUtilsTests.tmp");
|
||||
|
||||
/**
|
||||
* No restart + file should not be overwritten => file is created if it does
|
||||
|
||||
@@ -542,7 +542,7 @@ public class StaxEventItemReaderTests {
|
||||
@Test
|
||||
public void testDirectoryResource() throws Exception {
|
||||
|
||||
FileSystemResource resource = new FileSystemResource("build/data");
|
||||
FileSystemResource resource = new FileSystemResource("target/data");
|
||||
resource.getFile().mkdirs();
|
||||
assertTrue(resource.getFile().isDirectory());
|
||||
source.setResource(resource);
|
||||
|
||||
@@ -111,7 +111,7 @@ public class StaxEventItemWriterTests {
|
||||
|
||||
@Before
|
||||
public void setUp() throws Exception {
|
||||
File directory = new File("build/data");
|
||||
File directory = new File("target/data");
|
||||
directory.mkdirs();
|
||||
resource = new FileSystemResource(File.createTempFile("StaxEventWriterOutputSourceTests", ".xml", directory));
|
||||
writer = createItemWriter();
|
||||
|
||||
@@ -75,7 +75,7 @@ public class StaxEventItemWriterBuilderTests {
|
||||
|
||||
@Before
|
||||
public void setUp() throws IOException {
|
||||
File directory = new File("build/data");
|
||||
File directory = new File("target/data");
|
||||
directory.mkdirs();
|
||||
this.resource = new FileSystemResource(
|
||||
File.createTempFile("StaxEventItemWriterBuilderTests", ".xml", directory));
|
||||
|
||||
@@ -31,7 +31,7 @@ public class DatabaseTypeIntegrationTests {
|
||||
@Test
|
||||
public void testH2() throws Exception {
|
||||
DataSource dataSource = DatabaseTypeTestUtils.getDataSource(org.h2.Driver.class,
|
||||
"jdbc:h2:file:./build/data/sample");
|
||||
"jdbc:h2:file:./target/data/sample");
|
||||
assertEquals(DatabaseType.H2, DatabaseType.fromMetaData(dataSource));
|
||||
dataSource.getConnection();
|
||||
}
|
||||
@@ -39,7 +39,7 @@ public class DatabaseTypeIntegrationTests {
|
||||
@Test
|
||||
public void testDerby() throws Exception {
|
||||
DataSource dataSource = DatabaseTypeTestUtils.getDataSource(org.apache.derby.jdbc.EmbeddedDriver.class,
|
||||
"jdbc:derby:./build/derby-home/test;create=true", "sa", "");
|
||||
"jdbc:derby:./target/derby-home/test;create=true", "sa", "");
|
||||
assertEquals(DatabaseType.DERBY, DatabaseType.fromMetaData(dataSource));
|
||||
dataSource.getConnection();
|
||||
}
|
||||
|
||||
@@ -60,8 +60,8 @@ public class LastModifiedResourceComparatorTests {
|
||||
|
||||
@Test
|
||||
public void testCompareNewWithOldAfterCopy() throws Exception {
|
||||
File temp1 = new File("build/temp1.txt");
|
||||
File temp2 = new File("build/temp2.txt");
|
||||
File temp1 = new File("target/temp1.txt");
|
||||
File temp2 = new File("target/temp2.txt");
|
||||
if (temp1.exists()) temp1.delete();
|
||||
if (temp2.exists()) temp2.delete();
|
||||
temp1.getParentFile().mkdirs();
|
||||
|
||||
@@ -28,7 +28,7 @@ public class DerbyDataSourceFactoryBean extends AbstractFactoryBean<DataSource>
|
||||
|
||||
private static Log logger = LogFactory.getLog(DerbyDataSourceFactoryBean.class);
|
||||
|
||||
private String dataDirectory = "build/derby-home";
|
||||
private String dataDirectory = "target/derby-home";
|
||||
|
||||
public void setDataDirectory(String dataDirectory) {
|
||||
this.dataDirectory = dataDirectory;
|
||||
@@ -42,7 +42,7 @@ public class DerbyDataSourceFactoryBean extends AbstractFactoryBean<DataSource>
|
||||
System.setProperty("derby.storage.pageCacheSize", "100");
|
||||
|
||||
final EmbeddedDataSource ds = new EmbeddedDataSource();
|
||||
ds.setDatabaseName("build/derbydb");
|
||||
ds.setDatabaseName("target/derbydb");
|
||||
ds.setCreateDatabase("create");
|
||||
|
||||
logger.info("Created instance of " + ds.toString());
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Placeholders batch.*
|
||||
# for Derby:
|
||||
batch.jdbc.driver=org.apache.derby.jdbc.EmbeddedDriver
|
||||
batch.jdbc.url=jdbc:derby:build/derby-home/test;create=true
|
||||
batch.jdbc.url=jdbc:derby:target/derby-home/test;create=true
|
||||
batch.jdbc.user=app
|
||||
batch.jdbc.password=
|
||||
batch.jdbc.testWhileIdle=false
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="dataSource" class="test.jdbc.datasource.DerbyDataSourceFactoryBean">
|
||||
<property name="dataDirectory" value="build/derby-home"/>
|
||||
<property name="dataDirectory" value="target/derby-home"/>
|
||||
</bean>
|
||||
|
||||
<bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
|
||||
|
||||
@@ -929,7 +929,7 @@ source view of the configuration is as follows:
|
||||
|
||||
<bean id="directory"
|
||||
class="org.springframework.core.io.FileSystemResource">
|
||||
<constructor-arg value="build/test-outputs/test-dir" />
|
||||
<constructor-arg value="target/test-outputs/test-dir" />
|
||||
</bean>
|
||||
|
||||
For simplicity we are only displaying the job configuration itself
|
||||
|
||||
@@ -30,7 +30,7 @@ public class OutputFileListener {
|
||||
|
||||
private String inputKeyName = "fileName";
|
||||
|
||||
private String path = "file:./build/output/";
|
||||
private String path = "file:./target/output/";
|
||||
|
||||
public void setPath(String path) {
|
||||
this.path = path;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Placeholders batch.*
|
||||
# for H2:
|
||||
batch.jdbc.driver=org.h2.Driver
|
||||
batch.jdbc.url=jdbc:h2:file:build/data/h2
|
||||
batch.jdbc.url=jdbc:h2:file:target/data/h2
|
||||
batch.jdbc.user=sa
|
||||
batch.jdbc.password=
|
||||
batch.jdbc.testWhileIdle=false
|
||||
|
||||
@@ -74,7 +74,7 @@
|
||||
|
||||
<bean id="fileItemWriter1" class="org.springframework.batch.item.file.FlatFileItemWriter">
|
||||
<property name="name" value="fw1" />
|
||||
<property name="resource" value="file:build/test-outputs/CustomerReport1.txt" />
|
||||
<property name="resource" value="file:target/test-outputs/CustomerReport1.txt" />
|
||||
<property name="lineAggregator">
|
||||
<bean class="org.springframework.batch.item.file.transform.PassThroughLineAggregator" />
|
||||
</property>
|
||||
@@ -82,7 +82,7 @@
|
||||
|
||||
<bean id="fileItemWriter2" class="org.springframework.batch.item.file.FlatFileItemWriter">
|
||||
<property name="name" value="fw2" />
|
||||
<property name="resource" value="file:build/test-outputs/CustomerReport2.txt" />
|
||||
<property name="resource" value="file:target/test-outputs/CustomerReport2.txt" />
|
||||
<property name="lineAggregator">
|
||||
<bean class="org.springframework.batch.item.file.transform.PassThroughLineAggregator" />
|
||||
</property>
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
void execute() {
|
||||
def ant = new AntBuilder()
|
||||
ant.unzip(src:"src/main/resources/data/groovyJob/input/files.zip",
|
||||
dest:"build/groovyJob/staging")
|
||||
dest:"target/groovyJob/staging")
|
||||
}
|
||||
}
|
||||
</lang:inline-script>
|
||||
@@ -46,9 +46,9 @@
|
||||
class ZipTasklet {
|
||||
void execute() {
|
||||
def ant = new AntBuilder()
|
||||
ant.mkdir(dir:"build/groovyJob/output")
|
||||
ant.zip(destfile:"build/groovyJob/output/files.zip",
|
||||
basedir:"build/groovyJob/staging", includes:"**")
|
||||
ant.mkdir(dir:"target/groovyJob/output")
|
||||
ant.zip(destfile:"target/groovyJob/output/files.zip",
|
||||
basedir:"target/groovyJob/staging", includes:"**")
|
||||
}
|
||||
}
|
||||
</lang:inline-script>
|
||||
|
||||
@@ -61,6 +61,6 @@
|
||||
</bean>
|
||||
<bean id="outputResource" class="org.springframework.core.io.FileSystemResource">
|
||||
<constructor-arg type="java.lang.String"
|
||||
value="build/test-outputs/headerFooterOutput.txt" />
|
||||
value="target/test-outputs/headerFooterOutput.txt" />
|
||||
</bean>
|
||||
</beans>
|
||||
@@ -35,7 +35,7 @@
|
||||
<bean id="itemWriter" class="org.springframework.batch.sample.iosample.internal.MultiLineTradeItemWriter">
|
||||
<property name="delegate">
|
||||
<bean class="org.springframework.batch.item.file.FlatFileItemWriter">
|
||||
<property name="resource" value="file:build/test-outputs/multiLineOutput.txt" />
|
||||
<property name="resource" value="file:target/test-outputs/multiLineOutput.txt" />
|
||||
<property name="lineAggregator">
|
||||
<bean class="org.springframework.batch.item.file.transform.PassThroughLineAggregator" />
|
||||
</property>
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
|
||||
|
||||
<bean id="itemWriter" class="org.springframework.batch.item.file.FlatFileItemWriter">
|
||||
<property name="resource" value="file:build/test-outputs/multiRecordTypeOutput.txt" />
|
||||
<property name="resource" value="file:target/test-outputs/multiRecordTypeOutput.txt" />
|
||||
<property name="lineAggregator">
|
||||
<bean class="org.springframework.batch.sample.iosample.internal.DelegatingTradeLineAggregator">
|
||||
<property name="tradeLineAggregator" ref="tradeLineAggregator" />
|
||||
|
||||
@@ -31,6 +31,6 @@
|
||||
</bean>
|
||||
|
||||
<bean id="outputResource" class="org.springframework.core.io.FileSystemResource">
|
||||
<constructor-arg value="build/test-outputs/output.xml" />
|
||||
<constructor-arg value="target/test-outputs/output.xml" />
|
||||
</bean>
|
||||
</beans>
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
<bean id="writer" class="org.springframework.batch.item.file.FlatFileItemWriter">
|
||||
<property name="resource"
|
||||
value="file:build/test-outputs/20070122.testStream.multilineStep.txt" />
|
||||
value="file:target/test-outputs/20070122.testStream.multilineStep.txt" />
|
||||
<property name="lineAggregator">
|
||||
<bean
|
||||
class="org.springframework.batch.item.file.transform.PassThroughLineAggregator" />
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="fileItemWriter" class="org.springframework.batch.item.file.FlatFileItemWriter">
|
||||
<property name="resource" value="file:build/test-outputs/multilineOrderOutput.txt" />
|
||||
<property name="resource" value="file:target/test-outputs/multilineOrderOutput.txt" />
|
||||
<property name="lineAggregator">
|
||||
<bean class="org.springframework.batch.sample.domain.order.internal.OrderLineAggregator">
|
||||
<property name="aggregators" ref="outputAggregators"/>
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
</step>
|
||||
|
||||
<bean id="fileNameListener" class="org.springframework.batch.sample.common.OutputFileListener" scope="step">
|
||||
<property name="path" value="file:./build/output/file/" />
|
||||
<property name="path" value="file:./target/output/file/" />
|
||||
</bean>
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="outputTestReader" class="org.springframework.batch.item.file.MultiResourceItemReader" scope="prototype">
|
||||
<property name="resources" value="file:build/output/file/delimited*.csv" />
|
||||
<property name="resources" value="file:target/output/file/delimited*.csv" />
|
||||
<property name="delegate" ref="testItemReader" />
|
||||
</bean>
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
</step>
|
||||
|
||||
<bean id="fileNameListener" class="org.springframework.batch.sample.common.OutputFileListener" scope="step">
|
||||
<property name="path" value="file:./build/output/jdbc/" />
|
||||
<property name="path" value="file:./target/output/jdbc/" />
|
||||
</bean>
|
||||
|
||||
<bean id="itemReader" scope="step" autowire-candidate="false" class="org.springframework.batch.item.database.JdbcPagingItemReader">
|
||||
@@ -60,7 +60,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="outputTestReader" class="org.springframework.batch.item.file.MultiResourceItemReader" scope="prototype">
|
||||
<property name="resources" value="file:build/output/jdbc/*.csv" />
|
||||
<property name="resources" value="file:target/output/jdbc/*.csv" />
|
||||
<property name="delegate" ref="testItemReader" />
|
||||
</bean>
|
||||
|
||||
|
||||
@@ -61,6 +61,6 @@
|
||||
</bean>
|
||||
|
||||
<bean id="outputResource" class="org.springframework.core.io.FileSystemResource">
|
||||
<constructor-arg value="build/test-outputs/restartFileOutput.csv" />
|
||||
<constructor-arg value="target/test-outputs/restartFileOutput.csv" />
|
||||
</bean>
|
||||
</beans>
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
<bean id="customerReportItemWriter" class="org.springframework.batch.sample.domain.trade.internal.FlatFileCustomerCreditDao">
|
||||
<property name="itemWriter">
|
||||
<bean class="org.springframework.batch.item.file.FlatFileItemWriter">
|
||||
<property name="resource" value="file:build/test-outputs/20070122.testStream.CustomerReportStep.TEMP.txt" />
|
||||
<property name="resource" value="file:target/test-outputs/20070122.testStream.CustomerReportStep.TEMP.txt" />
|
||||
<property name="lineAggregator">
|
||||
<bean class="org.springframework.batch.item.file.transform.PassThroughLineAggregator" />
|
||||
</property>
|
||||
|
||||
@@ -66,8 +66,8 @@ public class CompositeItemWriterSampleFunctionalTests {
|
||||
|
||||
jobLauncherTestUtils.launchJob();
|
||||
|
||||
checkOutputFile("build/test-outputs/CustomerReport1.txt");
|
||||
checkOutputFile("build/test-outputs/CustomerReport2.txt");
|
||||
checkOutputFile("target/test-outputs/CustomerReport1.txt");
|
||||
checkOutputFile("target/test-outputs/CustomerReport2.txt");
|
||||
checkOutputTable(before);
|
||||
}
|
||||
|
||||
|
||||
@@ -41,14 +41,14 @@ public class GroovyJobFunctionalTests {
|
||||
|
||||
@Before
|
||||
public void removeOldData() throws IOException {
|
||||
FileUtils.deleteDirectory(new File("build/groovyJob"));
|
||||
FileUtils.deleteDirectory(new File("target/groovyJob"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testLaunchJob() throws Exception {
|
||||
assertFalse(new File("build/groovyJob/output/files.zip").exists());
|
||||
assertFalse(new File("target/groovyJob/output/files.zip").exists());
|
||||
jobLauncherTestUtils.launchJob();
|
||||
assertTrue(new File("build/groovyJob/output/files.zip").exists());
|
||||
assertTrue(new File("target/groovyJob/output/files.zip").exists());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -55,7 +55,7 @@ import org.springframework.util.DigestUtils;
|
||||
public class JsonSupportIntegrationTests {
|
||||
|
||||
private static final String INPUT_FILE_DIRECTORY = "src/test/resources/org/springframework/batch/item/json/";
|
||||
private static final String OUTPUT_FILE_DIRECTORY = "build/";
|
||||
private static final String OUTPUT_FILE_DIRECTORY = "target/";
|
||||
|
||||
@Before
|
||||
public void setUp() throws Exception {
|
||||
|
||||
@@ -43,7 +43,7 @@ public class MultilineJobFunctionalTests {
|
||||
private static final String EXPECTED_RESULT = "[Trade: [isin=UK21341EAH45,quantity=978,price=98.34,customer=customer1], Trade: [isin=UK21341EAH46,quantity=112,price=18.12,customer=customer2]]"
|
||||
+ "[Trade: [isin=UK21341EAH47,quantity=245,price=12.78,customer=customer2], Trade: [isin=UK21341EAH48,quantity=108,price=9.25,customer=customer3], Trade: [isin=UK21341EAH49,quantity=854,price=23.39,customer=customer4]]";
|
||||
|
||||
private Resource output = new FileSystemResource("build/test-outputs/20070122.testStream.multilineStep.txt");
|
||||
private Resource output = new FileSystemResource("target/test-outputs/20070122.testStream.multilineStep.txt");
|
||||
|
||||
@Test
|
||||
public void testJobLaunch() throws Exception {
|
||||
|
||||
@@ -32,7 +32,7 @@ import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
|
||||
"/job-runner-context.xml" })
|
||||
public class MultilineOrderJobFunctionalTests {
|
||||
|
||||
private static final String ACTUAL = "build/test-outputs/multilineOrderOutput.txt";
|
||||
private static final String ACTUAL = "target/test-outputs/multilineOrderOutput.txt";
|
||||
private static final String EXPECTED = "data/multilineOrderJob/result/multilineOrderOutput.txt";
|
||||
|
||||
@Autowired
|
||||
|
||||
@@ -46,7 +46,7 @@ import org.springframework.test.context.junit4.SpringRunner;
|
||||
@PropertySource("classpath:remote-chunking.properties")
|
||||
public class RemoteChunkingJobFunctionalTests {
|
||||
|
||||
private static final String BROKER_DATA_DIRECTORY = "build/activemq-data";
|
||||
private static final String BROKER_DATA_DIRECTORY = "target/activemq-data";
|
||||
|
||||
@Value("${broker.url}")
|
||||
private String brokerUrl;
|
||||
|
||||
@@ -42,7 +42,7 @@ import org.springframework.test.context.junit4.SpringRunner;
|
||||
@PropertySource("classpath:remote-partitioning.properties")
|
||||
public abstract class RemotePartitioningJobFunctionalTests {
|
||||
|
||||
private static final String BROKER_DATA_DIRECTORY = "build/activemq-data";
|
||||
private static final String BROKER_DATA_DIRECTORY = "target/activemq-data";
|
||||
|
||||
@Value("${broker.url}")
|
||||
private String brokerUrl;
|
||||
|
||||
@@ -28,7 +28,7 @@ public class OutputFileListenerTests {
|
||||
@Test
|
||||
public void testCreateOutputNameFromInput() {
|
||||
listener.createOutputNameFromInput(stepExecution);
|
||||
assertEquals("{outputFile=file:./build/output/foo.csv}", stepExecution.getExecutionContext().toString());
|
||||
assertEquals("{outputFile=file:./target/output/foo.csv}", stepExecution.getExecutionContext().toString());
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
@@ -38,7 +38,7 @@ public class DelimitedFunctionalTests extends AbstractIoSampleTests {
|
||||
@Override
|
||||
protected void pointReaderToOutput(ItemReader<CustomerCredit> reader) {
|
||||
JobParameters jobParameters = super.getUniqueJobParametersBuilder().addString("inputFile",
|
||||
"file:./build/test-outputs/delimitedOutput.csv").toJobParameters();
|
||||
"file:./target/test-outputs/delimitedOutput.csv").toJobParameters();
|
||||
StepExecution stepExecution = MetaDataInstanceFactory.createStepExecution(jobParameters);
|
||||
StepSynchronizationManager.close();
|
||||
StepSynchronizationManager.register(stepExecution);
|
||||
@@ -48,7 +48,7 @@ public class DelimitedFunctionalTests extends AbstractIoSampleTests {
|
||||
protected JobParameters getUniqueJobParameters() {
|
||||
return super.getUniqueJobParametersBuilder().addString("inputFile",
|
||||
"data/iosample/input/delimited.csv").addString("outputFile",
|
||||
"file:./build/test-outputs/delimitedOutput.csv").toJobParameters();
|
||||
"file:./target/test-outputs/delimitedOutput.csv").toJobParameters();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -33,7 +33,7 @@ public class FixedLengthFunctionalTests extends AbstractIoSampleTests {
|
||||
@Override
|
||||
protected void pointReaderToOutput(ItemReader<CustomerCredit> reader) {
|
||||
JobParameters jobParameters = super.getUniqueJobParametersBuilder().addString("inputFile",
|
||||
"file:./build/test-outputs/fixedLengthOutput.txt").toJobParameters();
|
||||
"file:./target/test-outputs/fixedLengthOutput.txt").toJobParameters();
|
||||
StepExecution stepExecution = MetaDataInstanceFactory.createStepExecution(jobParameters);
|
||||
StepSynchronizationManager.close();
|
||||
StepSynchronizationManager.register(stepExecution);
|
||||
@@ -43,7 +43,7 @@ public class FixedLengthFunctionalTests extends AbstractIoSampleTests {
|
||||
protected JobParameters getUniqueJobParameters() {
|
||||
return super.getUniqueJobParametersBuilder().addString("inputFile",
|
||||
"data/iosample/input/fixedLength.txt").addString("outputFile",
|
||||
"file:./build/test-outputs/fixedLengthOutput.txt").toJobParameters();
|
||||
"file:./target/test-outputs/fixedLengthOutput.txt").toJobParameters();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
|
||||
"/job-runner-context.xml" })
|
||||
public class MultiLineFunctionalTests {
|
||||
|
||||
private static final String OUTPUT_FILE = "build/test-outputs/multiLineOutput.txt";
|
||||
private static final String OUTPUT_FILE = "target/test-outputs/multiLineOutput.txt";
|
||||
|
||||
private static final String INPUT_FILE = "src/main/resources/data/iosample/input/multiLine.txt";
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
|
||||
"/job-runner-context.xml" })
|
||||
public class MultiRecordTypeFunctionalTests {
|
||||
|
||||
private static final String OUTPUT_FILE = "build/test-outputs/multiRecordTypeOutput.txt";
|
||||
private static final String OUTPUT_FILE = "target/test-outputs/multiRecordTypeOutput.txt";
|
||||
|
||||
private static final String INPUT_FILE = "src/main/resources/data/iosample/input/multiRecordType.txt";
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ public class MultiResourceFunctionalTests extends AbstractIoSampleTests {
|
||||
@Override
|
||||
protected void pointReaderToOutput(ItemReader<CustomerCredit> reader) {
|
||||
JobParameters jobParameters = super.getUniqueJobParametersBuilder().addString(
|
||||
"input.file.path", "file:build/test-outputs/multiResourceOutput.csv.*").toJobParameters();
|
||||
"input.file.path", "file:target/test-outputs/multiResourceOutput.csv.*").toJobParameters();
|
||||
StepExecution stepExecution = MetaDataInstanceFactory.createStepExecution(jobParameters);
|
||||
StepSynchronizationManager.close();
|
||||
StepSynchronizationManager.register(stepExecution);
|
||||
@@ -48,7 +48,7 @@ public class MultiResourceFunctionalTests extends AbstractIoSampleTests {
|
||||
protected JobParameters getUniqueJobParameters() {
|
||||
JobParametersBuilder builder = super.getUniqueJobParametersBuilder();
|
||||
return builder.addString("input.file.path", "classpath:data/iosample/input/delimited*.csv").addString(
|
||||
"output.file.path", "file:build/test-outputs/multiResourceOutput.csv").toJobParameters();
|
||||
"output.file.path", "file:target/test-outputs/multiResourceOutput.csv").toJobParameters();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -74,7 +74,7 @@ public class TwoJobInstancesDelimitedFunctionalTests {
|
||||
|
||||
private void verifyOutput(int expected) throws Exception {
|
||||
JobParameters jobParameters = new JobParametersBuilder().addString("inputFile",
|
||||
"file:./build/test-outputs/delimitedOutput.csv").toJobParameters();
|
||||
"file:./target/test-outputs/delimitedOutput.csv").toJobParameters();
|
||||
StepExecution stepExecution = MetaDataInstanceFactory.createStepExecution(jobParameters);
|
||||
|
||||
int count = StepScopeTestUtils.doInStepScope(stepExecution, new Callable<Integer>() {
|
||||
@@ -101,6 +101,6 @@ public class TwoJobInstancesDelimitedFunctionalTests {
|
||||
|
||||
protected JobParameters getJobParameters(String fileName) {
|
||||
return new JobParametersBuilder().addLong("timestamp", new Date().getTime()).addString("inputFile", fileName)
|
||||
.addString("outputFile", "file:./build/test-outputs/delimitedOutput.csv").toJobParameters();
|
||||
.addString("outputFile", "file:./target/test-outputs/delimitedOutput.csv").toJobParameters();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user