BATCH-1920 - Corrected pom and removed unused reference to JdbcTemplate

This commit is contained in:
Michael Minella
2012-12-18 13:46:10 -06:00
parent 96f870af4f
commit 95ccb1a229
3 changed files with 4 additions and 15 deletions

View File

@@ -20,7 +20,7 @@
<dependency>
<groupId>com.vmware.sqlfire</groupId>
<artifactId>sqlfireclient</artifactId>
<version>1.0.3</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.springframework.batch</groupId>

View File

@@ -9,7 +9,6 @@
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd">
<beans:import resource="classpath:/META-INF/spring/config-beans.xml"/>
<!-- <beans:import resource="classpath:/META-INF/spring/batch-beans.xml"/> -->
<beans:import resource="classpath:/META-INF/spring/jobs/messaging/rabbitmq-beans.xml"/>
<beans:import resource="classpath:/META-INF/spring/jobs/amqp/amqp-example-job-beans.xml"/>

View File

@@ -2,18 +2,15 @@ package org.springframework.batch.sample;
import static org.junit.Assert.assertTrue;
import javax.sql.DataSource;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.batch.core.explore.JobExplorer;
import org.springframework.batch.test.JobLauncherTestUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.simple.SimpleJdbcTemplate;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
/**
/**
* Run the job to read from the "test.inbound" queue, process the messages and write them to the "test.outbound" queue:
* mvn -q exec:java -Dexec.mainClass="org.springframework.batch.core.launch.support.CommandLineJobRunner" \
* -Dexec.arguments="classpath*:/META-INF/spring/jobs/amqp/amqp-example-job.xml,amqp-example-job"
@@ -25,21 +22,14 @@ public class AMQPJobFunctionalTests {
@Autowired
private JobLauncherTestUtils jobLauncherTestUtils;
private SimpleJdbcTemplate simpleJdbcTemplate;
@Autowired
private JobExplorer jobExplorer;
@Autowired
public void setDataSource(DataSource dataSource) {
this.simpleJdbcTemplate = new SimpleJdbcTemplate(dataSource);
}
@Test
public void testLaunchJob() throws Exception {
jobLauncherTestUtils.launchJob();
int count = jobExplorer.getJobInstances("amqp-example-job", 0, 1).size();
assertTrue(count > 0);