From 93af004f5c512edef074fa075308cacc48f16997 Mon Sep 17 00:00:00 2001 From: "Arsen A. Gutsal" Date: Sat, 21 Mar 2015 12:03:26 +0200 Subject: [PATCH] plugin version changed to 1.4.1, camel version upgraded to 2.15.0, test fixed --- RoutingGrailsPlugin.groovy | 2 +- grails-app/conf/BuildConfig.groovy | 2 +- .../grails/routing/RoutesTests.groovy | 26 +++++-------------- 3 files changed, 8 insertions(+), 22 deletions(-) diff --git a/RoutingGrailsPlugin.groovy b/RoutingGrailsPlugin.groovy index 11f7587..1df3e62 100755 --- a/RoutingGrailsPlugin.groovy +++ b/RoutingGrailsPlugin.groovy @@ -14,7 +14,7 @@ import javax.activation.DataHandler import javax.security.auth.Subject class RoutingGrailsPlugin { - def version = '1.4.0' + def version = '1.4.1' def grailsVersion = '2.0.0 > *' def artefacts = [new RouteArtefactHandler()] def dependsOn = [:] diff --git a/grails-app/conf/BuildConfig.groovy b/grails-app/conf/BuildConfig.groovy index 659b865..c8ad3b9 100644 --- a/grails-app/conf/BuildConfig.groovy +++ b/grails-app/conf/BuildConfig.groovy @@ -1,6 +1,6 @@ grails.project.work.dir = 'target' -def camelVersion = '2.13.2' +def camelVersion = '2.15.0' grails.project.fork = [ diff --git a/test/integration/grails/routing/RoutesTests.groovy b/test/integration/grails/routing/RoutesTests.groovy index a93429d..032694d 100644 --- a/test/integration/grails/routing/RoutesTests.groovy +++ b/test/integration/grails/routing/RoutesTests.groovy @@ -6,22 +6,16 @@ import org.junit.* import org.apache.camel.CamelContext import org.apache.camel.test.junit4.CamelTestSupport import org.apache.camel.builder.RouteBuilder +import org.apache.camel.builder.AdviceWithRouteBuilder; class RoutesTests extends CamelTestSupport { - - def camelContext - def producerTemplate - - @Override - protected CamelContext createCamelContext() throws Exception { - return camelContext - } + //def producerTemplate @Before void setUp() { super.setUp() - camelContext.addRoutes( + context.addRoutes( new RouteBuilder(){ @Override void configure(){ @@ -30,19 +24,11 @@ class RoutesTests extends CamelTestSupport { }) } - @After - void tearDown() { - camelContext.stop() - } - @Test - void testSimpleRoute() { - def mockEndpoint - mockEndpoint = getMockEndpoint('mock:bar') - - mockEndpoint.expectedMessageCount(1) + void testSimpleRoute() { + getMockEndpoint('mock:bar').expectedMessageCount(1) - producerTemplate.sendBody('direct:foo', 'Hello World') + template.sendBody('direct:foo', 'Hello World') assertMockEndpointsSatisfied() }