camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [3/9] camel git commit: Fixed test
Date Mon, 02 Mar 2015 07:17:10 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/fe86d227
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/fe86d227
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/fe86d227

Branch: refs/heads/master
Commit: fe86d227157d90b6d978c78b0bf131808d2d19b9
Parents: 7d19340
Author: Claus Ibsen <davsclaus@apache.org>
Authored: Sun Mar 1 13:55:49 2015 +0100
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Mon Mar 2 08:17:28 2015 +0100

----------------------------------------------------------------------
 ...HttpComponentConfigurationAndDocumentationTest.java | 13 -------------
 .../JettyRouteWithUnknownSocketPropertiesTest.java     |  3 ++-
 .../JettyRouteWithUnknownSslSocketPropertiesTest.java  |  3 ++-
 3 files changed, 4 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/fe86d227/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyHttpComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyHttpComponentConfigurationAndDocumentationTest.java
b/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyHttpComponentConfigurationAndDocumentationTest.java
index e18e911..785c9be 100644
--- a/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyHttpComponentConfigurationAndDocumentationTest.java
+++ b/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyHttpComponentConfigurationAndDocumentationTest.java
@@ -16,12 +16,9 @@
  */
 package org.apache.camel.component.jetty;
 
-import org.apache.camel.CamelContext;
 import org.apache.camel.ComponentConfiguration;
 import org.apache.camel.EndpointConfiguration;
-import org.apache.camel.impl.DefaultCamelContext;
 import org.apache.camel.test.junit4.CamelTestSupport;
-import org.junit.Ignore;
 import org.junit.Test;
 
 public class JettyHttpComponentConfigurationAndDocumentationTest extends CamelTestSupport
{
@@ -43,16 +40,6 @@ public class JettyHttpComponentConfigurationAndDocumentationTest extends
CamelTe
         ComponentConfiguration compConf = comp.createComponentConfiguration();
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
-        assertTrue(json.contains("\"httpClientMaxThreads\": { \"kind\": \"parameter\", \"type\":
\"integer\""));
-        assertTrue(json.contains("\"sessionSupport\": { \"kind\": \"parameter\", \"type\":
\"boolean\", \"javaType\": \"boolean\""));
-    }
-
-    @Test
-    @Ignore // TODO Need to investigate why this fails while html is present
-    public void testComponentDocumentation() throws Exception {
-        CamelContext context = new DefaultCamelContext();
-        String html = context.getComponentDocumentation("jetty");
-        assertNotNull("Should have found some auto-generated HTML", html);
     }
 
 }

http://git-wip-us.apache.org/repos/asf/camel/blob/fe86d227/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSocketPropertiesTest.java
----------------------------------------------------------------------
diff --git a/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSocketPropertiesTest.java
b/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSocketPropertiesTest.java
index 1c16248..298ffef 100644
--- a/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSocketPropertiesTest.java
+++ b/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSocketPropertiesTest.java
@@ -56,7 +56,8 @@ public class JettyRouteWithUnknownSocketPropertiesTest extends BaseJettyTest
{
             context.start();
             fail("Should have thrown exception");
         } catch (Exception e) {
-            assertTrue(e.getMessage().endsWith("Unknown parameters=[{doesNotExist=2000}]"));
+            IllegalArgumentException iae = assertIsInstanceOf(IllegalArgumentException.class,
e.getCause());
+            assertTrue(iae.getMessage().endsWith("Unknown parameters=[{doesNotExist=2000}]"));
         }
     }
 

http://git-wip-us.apache.org/repos/asf/camel/blob/fe86d227/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSslSocketPropertiesTest.java
----------------------------------------------------------------------
diff --git a/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSslSocketPropertiesTest.java
b/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSslSocketPropertiesTest.java
index 091bf15..cd00ae1 100644
--- a/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSslSocketPropertiesTest.java
+++ b/components/camel-jetty9/src/test/java/org/apache/camel/component/jetty/JettyRouteWithUnknownSslSocketPropertiesTest.java
@@ -56,7 +56,8 @@ public class JettyRouteWithUnknownSslSocketPropertiesTest extends BaseJettyTest
             context.start();
             fail("Should have thrown exception");
         } catch (Exception e) {
-            assertTrue("Actual message: " + e.getMessage(), e.getMessage().endsWith("Unknown
parameters=[{doesNotExist=2000}]"));
+            IllegalArgumentException iae = assertIsInstanceOf(IllegalArgumentException.class,
e.getCause());
+            assertTrue("Actual message: " + iae.getMessage(), iae.getMessage().endsWith("Unknown
parameters=[{doesNotExist=2000}]"));
         }
     }
 


Mime
View raw message