camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [3/9] git commit: Fixed test
Date Tue, 11 Mar 2014 08:51:30 GMT
Fixed test


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/d22d33ae
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/d22d33ae
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/d22d33ae

Branch: refs/heads/master
Commit: d22d33ae49946d8ed2586590872d19eb16b3acf5
Parents: f622f8e
Author: Claus Ibsen <davsclaus@apache.org>
Authored: Tue Mar 11 09:22:43 2014 +0100
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Tue Mar 11 09:22:43 2014 +0100

----------------------------------------------------------------------
 .../component/quartz2/QuartzRouteFireNowTest.java    | 15 +++++++++++++++
 1 file changed, 15 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/d22d33ae/components/camel-quartz2/src/test/java/org/apache/camel/component/quartz2/QuartzRouteFireNowTest.java
----------------------------------------------------------------------
diff --git a/components/camel-quartz2/src/test/java/org/apache/camel/component/quartz2/QuartzRouteFireNowTest.java
b/components/camel-quartz2/src/test/java/org/apache/camel/component/quartz2/QuartzRouteFireNowTest.java
index c45b3c4..d45f21d 100644
--- a/components/camel-quartz2/src/test/java/org/apache/camel/component/quartz2/QuartzRouteFireNowTest.java
+++ b/components/camel-quartz2/src/test/java/org/apache/camel/component/quartz2/QuartzRouteFireNowTest.java
@@ -17,11 +17,26 @@
 package org.apache.camel.component.quartz2;
 
 import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.mock.MockEndpoint;
+import org.junit.Test;
 
 /**
  * @version 
  */
 public class QuartzRouteFireNowTest extends BaseQuartzTest {
+
+    protected MockEndpoint resultEndpoint;
+
+    @Test
+    public void testQuartzRoute() throws Exception {
+        resultEndpoint = getMockEndpoint("mock:result");
+        resultEndpoint.expectedMessageCount(2);
+        resultEndpoint.message(0).header("triggerName").isEqualTo("myTimerName");
+        resultEndpoint.message(0).header("triggerGroup").isEqualTo("myGroup");
+
+        // lets test the receive worked
+        resultEndpoint.assertIsSatisfied();
+    }
     
     @Override
     protected RouteBuilder createRouteBuilder() {


Mime
View raw message