You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2016/05/26 17:10:28 UTC

[2/2] camel git commit: Fixed CS. This closes #999. This closes #997. This closes #996.

Fixed CS. This closes #999. This closes #997. This closes #996.


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

Branch: refs/heads/master
Commit: cefe7f332e35751fd0a2bb2de6e106b0630bac8d
Parents: a38d0ff
Author: Claus Ibsen <da...@apache.org>
Authored: Thu May 26 19:10:17 2016 +0200
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu May 26 19:10:17 2016 +0200

----------------------------------------------------------------------
 .../java/org/apache/camel/converter/DurationConverterTest.java | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/cefe7f33/camel-core/src/test/java/org/apache/camel/converter/DurationConverterTest.java
----------------------------------------------------------------------
diff --git a/camel-core/src/test/java/org/apache/camel/converter/DurationConverterTest.java b/camel-core/src/test/java/org/apache/camel/converter/DurationConverterTest.java
index ce6d810..c1e13b3 100644
--- a/camel-core/src/test/java/org/apache/camel/converter/DurationConverterTest.java
+++ b/camel-core/src/test/java/org/apache/camel/converter/DurationConverterTest.java
@@ -16,10 +16,7 @@
  */
 package org.apache.camel.converter;
 
-
 import java.time.Duration;
-import java.util.Date;
-import java.util.TimeZone;
 
 import org.apache.camel.ContextTestSupport;
 import org.apache.camel.TypeConversionException;
@@ -41,6 +38,7 @@ public class DurationConverterTest extends ContextTestSupport {
         Duration duration = Duration.parse("P60000000000000D");
         try {
             context.getTypeConverter().convertTo(long.class, duration);
+            fail("Should throw exception");
         } catch (TypeConversionException e) {
             assertIsInstanceOf(ArithmeticException.class, e.getCause().getCause());
         }
@@ -55,7 +53,7 @@ public class DurationConverterTest extends ContextTestSupport {
     }
 
     public void testToString() throws Exception {
-        Duration duration= Duration.parse("PT2H6M20.31S");
+        Duration duration = Duration.parse("PT2H6M20.31S");
 
         String durationAsString = context.getTypeConverter().convertTo(String.class, duration);
         assertNotNull(durationAsString);