camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject svn commit: r1207287 - in /camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala: converter/ dsl/ dsl/builder/ dsl/builder/scan/
Date Mon, 28 Nov 2011 15:16:58 GMT
Author: ningjiang
Date: Mon Nov 28 15:16:45 2011
New Revision: 1207287

URL: http://svn.apache.org/viewvc?rev=1207287&view=rev
Log:
Clean up the camel-scala unit tests

Modified:
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/converter/ScalaTypeConverterTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/AggregatorTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/BasicRouteBuilderTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentBasedRouterTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentEnricherTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DataFormatTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DelayerTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/EnricherTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExceptionHandlerTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExchangePatternTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/FilterRouteBuilderTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/HeaderContentBasedRouterTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdempotentConsumerTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/InterceptSendToTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoadBalancerTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopCopyTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopNoCopyTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/MulticastTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/OnExceptionTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineAndMulticastTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineRouteBuilderTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RecipientListRouteTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ResequencerTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RollbackTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteErrorHandlerTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteIdTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ScalaTestSupport.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetBodyTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetExchangePatternTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetHeaderTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SimpleBeanTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SplitterRouteBuilderTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ThrottlerTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/TryCatchFinallyTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/WiretapTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/XPathContentBasedRouterTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/RouteBuilderUnwrapTest.scala
    camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/scan/DiscoverRouteBuilderTest.scala

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/converter/ScalaTypeConverterTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/converter/ScalaTypeConverterTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/converter/ScalaTypeConverterTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/converter/ScalaTypeConverterTest.scala Mon Nov 28 15:16:45 2011
@@ -16,19 +16,22 @@
  */
 package org.apache.camel.scala.converter;
 
+import javax.xml.parsers.DocumentBuilderFactory
+import org.apache.camel.test.junit4.CamelTestSupport
+
 import org.junit.Assert._
+import org.junit.Test
+import org.w3c.dom.Document
 
-import org.apache.camel.ContextTestSupport
 import scala.xml.Elem
 
-import javax.xml.parsers.DocumentBuilderFactory
-import org.w3c.dom.Document
 
 /**
  * Test case for ScalaTypeConverter
  */
-class ScalaTypeConverterTest extends ContextTestSupport {
+class ScalaTypeConverterTest extends CamelTestSupport {
   
+  @Test
   def testDocumentConverter = {
     val exchange = context.getEndpoint("direct:start").createExchange
 
@@ -45,6 +48,7 @@ class ScalaTypeConverterTest extends Con
     assertEquals(<persons/>, result)
   }
 
+  @Test
   def testDomDocumentToElemConverter = {
     val exchange = context.getEndpoint("direct:start").createExchange
 
@@ -59,6 +63,7 @@ class ScalaTypeConverterTest extends Con
     assertEquals(<persons/>, result)
   }
 
+  @Test
   def testDomNodeToElemConverter = {
     val exchange = context.getEndpoint("direct:start").createExchange
 

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/AggregatorTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/AggregatorTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/AggregatorTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/AggregatorTest.scala Mon Nov 28 15:16:45 2011
@@ -17,6 +17,7 @@
 package org.apache.camel.scala.dsl;
  
 import org.apache.camel.processor.aggregate.UseLatestAggregationStrategy;
+import org.junit.Test
 import builder.RouteBuilder
 
 /**
@@ -26,6 +27,7 @@ class AggregatorTest extends ScalaTestSu
   
   val count = 100
   
+  @Test
   def testSimpleAggregator = {
     "mock:a" expect { _.received("message " + count) } 
     test {
@@ -35,6 +37,7 @@ class AggregatorTest extends ScalaTestSu
     }
   }
 
+ @Test
  def testBlockAggregator = {
     "mock:b" expect { _.received("message " + count) } 
     test {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/BasicRouteBuilderTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/BasicRouteBuilderTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/BasicRouteBuilderTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/BasicRouteBuilderTest.scala Mon Nov 28 15:16:45 2011
@@ -17,11 +17,14 @@
 package org.apache.camel
 package scala.dsl
 
+import org.junit.Test
 import builder.RouteBuilder
 
 class BasicRouteBuilderTest extends ScalaTestSupport {
 
+  @Test
   def testBasicRouteArrowSyntax() = assertBasicRoute("direct:a", "mock:a")
+  @Test
   def testBasicRouteTextSyntax() = assertBasicRoute("direct:b", "mock:b")
 
   def assertBasicRoute(from: String, to: String) = {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentBasedRouterTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentBasedRouterTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentBasedRouterTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentBasedRouterTest.scala Mon Nov 28 15:16:45 2011
@@ -15,11 +15,13 @@
  * limitations under the License.
  */
 package org.apache.camel.scala.dsl;
- 
+
+import org.junit.Test
 import builder.RouteBuilder
 
 class ContentBasedRouterTest extends ScalaTestSupport {
 
+  @Test
   def testSimpleContentBasedRouter = {
     "mock:polyglot" expect {_.expectedMessageCount(3)}
     "mock:english" expect {_.received("<hello/>")}

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentEnricherTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentEnricherTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentEnricherTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ContentEnricherTest.scala Mon Nov 28 15:16:45 2011
@@ -16,11 +16,12 @@
  */
 package org.apache.camel
 package scala.dsl;
- 
+
+import org.junit.Test
 import builder.RouteBuilder
 
 class ContentEnricherTest extends ScalaTestSupport {
-  
+  @Test
   def testContentEnricherBySimpleProcessor = {
     "mock:a" expect { _.received ("James says hello", 
                                   "Hadrian says hello",
@@ -29,6 +30,7 @@ class ContentEnricherTest extends ScalaT
     "mock:a" assert()
   }
   
+  @Test
   def testContentEnricherByProcessorDef = {
     "mock:b" expect { _.received ("hello from the UK", 
                                   "hallo vanuit Belgie",
@@ -37,6 +39,7 @@ class ContentEnricherTest extends ScalaT
     "mock:b" assert()
   }
   
+  @Test
   def testContentEnricherWithVelocity = {
     "mock:c" expect { _.received ("<hello>James</hello>", 
                                   "<hello>Hadrian</hello>",

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DataFormatTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DataFormatTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DataFormatTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DataFormatTest.scala Mon Nov 28 15:16:45 2011
@@ -16,7 +16,8 @@
  */
 package org.apache.camel.scala
 package dsl;
- 
+
+import org.junit.Test
 import builder.RouteBuilder
 import test.Adult
 
@@ -24,7 +25,8 @@ import test.Adult
  * Test case for working with data formats
  */
 class DataFormatTest extends ScalaTestSupport {
-  
+ 
+  @Test
   def testSimpleTrottler = {
     val person = new Adult("Captain Nemo")
     "mock:a" expect { _.received(person) } 

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DelayerTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DelayerTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DelayerTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/DelayerTest.scala Mon Nov 28 15:16:45 2011
@@ -15,7 +15,8 @@
  * limitations under the License.
  */
 package org.apache.camel.scala.dsl;
- 
+
+import org.junit.Test
 import builder.RouteBuilder
 
 /**
@@ -23,6 +24,7 @@ import builder.RouteBuilder
  */
 class DelayerTest extends ScalaTestSupport {
   
+  @Test
   def testSimpleDelayer = {
     "mock:a" expect { _.count = 0 }      
     "seda:a" ! "any given message"   

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/EnricherTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/EnricherTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/EnricherTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/EnricherTest.scala Mon Nov 28 15:16:45 2011
@@ -16,7 +16,8 @@
  */
 package org.apache.camel
 package scala.dsl
- 
+
+import org.junit.Test
 import builder.RouteBuilder
 
 /**
@@ -24,7 +25,9 @@ import builder.RouteBuilder
  */
 class EnricherTest extends ScalaTestSupport {
   
+  @Test
   def testSimpleEnricher = testEnricher("direct:a", "mock:a")
+  @Test
   def testBlockEnricher = testEnricher("direct:b", "mock:b")
   
   def testEnricher(direct: String, mock: String) = {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExceptionHandlerTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExceptionHandlerTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExceptionHandlerTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExceptionHandlerTest.scala Mon Nov 28 15:16:45 2011
@@ -17,6 +17,7 @@
 package org.apache.camel
 package scala.dsl;
 
+import org.junit.Test
 import builder.RouteBuilder
 import junit.framework.Assert._
 
@@ -27,6 +28,7 @@ class ExceptionHandlerTest extends Scala
 
   var handled = false;
 
+  @Test
   def testTryCatchFinally = {
     "mock:a" expect { _.count = 1 }
     "mock:b" expect { _.count = 1 }

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExchangePatternTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExchangePatternTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExchangePatternTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ExchangePatternTest.scala Mon Nov 28 15:16:45 2011
@@ -17,11 +17,13 @@
 package org.apache.camel
 package scala.dsl
 
+import org.junit.Test
 import builder.RouteBuilder
 import ExchangePattern.{InOnly, InOut}
 
 class ExchangePatternTest extends ScalaTestSupport {
 
+  @Test
   def testInOnly() = {
     getMockEndpoint("mock:a").expectedMessageCount(1)
     getMockEndpoint("mock:a").expectedExchangePattern(InOnly)
@@ -33,6 +35,7 @@ class ExchangePatternTest extends ScalaT
     assertMockEndpointsSatisfied
   }
 
+  @Test
   def testRequestInOnly() = {
     getMockEndpoint("mock:a").expectedMessageCount(1)
     getMockEndpoint("mock:a").expectedExchangePattern(InOnly)
@@ -44,6 +47,7 @@ class ExchangePatternTest extends ScalaT
     assertMockEndpointsSatisfied
   }
 
+  @Test
   def testInOut() = {
     getMockEndpoint("mock:b").expectedMessageCount(1)
     getMockEndpoint("mock:b").expectedExchangePattern(InOut)
@@ -55,17 +59,19 @@ class ExchangePatternTest extends ScalaT
     assertMockEndpointsSatisfied
   }
 
+  @Test
   def testRequestInOut() = {
     getMockEndpoint("mock:b").expectedMessageCount(1)
     getMockEndpoint("mock:b").expectedExchangePattern(InOut)
     getMockEndpoint("mock:result").expectedMessageCount(1)
     getMockEndpoint("mock:result").expectedExchangePattern(InOut)
 
-    template.requestBody("direct:b", "Hello World")
+    template.requestBody("direct:b", "Hello World");
 
     assertMockEndpointsSatisfied
   }
 
+  @Test
   def testMixed() = {
     getMockEndpoint("mock:c").expectedMessageCount(1)
     getMockEndpoint("mock:c").expectedExchangePattern(InOut)

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/FilterRouteBuilderTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/FilterRouteBuilderTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/FilterRouteBuilderTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/FilterRouteBuilderTest.scala Mon Nov 28 15:16:45 2011
@@ -15,17 +15,20 @@
  * limitations under the License.
  */
 package org.apache.camel.scala.dsl;
- 
+
+import org.junit.Test
 import builder.RouteBuilder
 
 class FilterRouteBuilderTest extends ScalaTestSupport {
 
+  @Test
   def testSimpleFilter() = {
     "mock:a" expect {_.expectedMessageCount(1)}
     "direct:a" ! ("<hello/>", "<hellos/>")
     "mock:a" assert
   }
 
+  @Test
   def testFilterWithAlternatives() = {
     "mock:b" expect {_.expectedMessageCount(1)}
     "mock:c" expect {_.expectedMessageCount(1)}

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/HeaderContentBasedRouterTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/HeaderContentBasedRouterTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/HeaderContentBasedRouterTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/HeaderContentBasedRouterTest.scala Mon Nov 28 15:16:45 2011
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.scala.dsl
 
+import org.junit.Test
 import builder.RouteBuilder
 
 /**
@@ -23,6 +24,7 @@ import builder.RouteBuilder
  */
 class HeaderContentBasedRouterTest extends ScalaTestSupport {
 
+  @Test
   def testXPathContentBasedRouter = {
     "mock:foo" expect {_.expectedBodiesReceived("Hello Foo")}
     "mock:bar" expect {_.expectedBodiesReceived("Hello Bar")}

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdTest.scala Mon Nov 28 15:16:45 2011
@@ -17,11 +17,13 @@
 package org.apache.camel
 package scala.dsl
 
+import org.junit.Test
 import builder.RouteBuilder
 import junit.framework.Assert.assertEquals
 
 class IdTest extends ScalaTestSupport {
 
+  @Test
   def testRouteA = {
     "mock:a" expect { _.expectedMessageCount(1)}
     "mock:result" expect { _.expectedMessageCount(1)}
@@ -35,6 +37,7 @@ class IdTest extends ScalaTestSupport {
     assertEquals("foo", context.getRouteDefinition("route-a").getOutputs.get(0).getId())
   }
 
+  @Test
   def testRouteB = {
     "mock:b" expect { _.expectedMessageCount(1)}
     "mock:result" expect { _.expectedMessageCount(1)}

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdempotentConsumerTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdempotentConsumerTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdempotentConsumerTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/IdempotentConsumerTest.scala Mon Nov 28 15:16:45 2011
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.scala.dsl;
 
+import org.junit.Test
 import builder.RouteBuilder
 import org.apache.camel.processor.idempotent.MemoryIdempotentRepository
 import org.apache.camel.spi.IdempotentRepository
@@ -26,7 +27,9 @@ import org.apache.camel.{Processor, Exch
  */
 class IdempotentConsumerTest extends ScalaTestSupport {
 
+  @Test
   def testSimple() = doTest("direct:a", "mock:a")
+  @Test
   def testBlock() = doTest("direct:b", "mock:b")
   
   

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/InterceptSendToTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/InterceptSendToTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/InterceptSendToTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/InterceptSendToTest.scala Mon Nov 28 15:16:45 2011
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.scala.dsl
 
+import org.junit.Test
 import builder.{RouteBuilderSupport, RouteBuilder}
 import org.apache.camel.processor.intercept.InterceptSendToFaultTest
 
@@ -24,6 +25,7 @@ import org.apache.camel.processor.interc
  */
 class InterceptSendToTest extends ScalaTestSupport {
 
+  @Test
   def testSimpleSendTo = {
     "mock:bar" expect {_.received("Hello World")}
     "mock:detour" expect {_.received("Hello World")}

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoadBalancerTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoadBalancerTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoadBalancerTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoadBalancerTest.scala Mon Nov 28 15:16:45 2011
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.scala.dsl;
 
+import org.junit.Test
 import builder.RouteBuilder
 
 /**
@@ -23,6 +24,7 @@ import builder.RouteBuilder
  */
 class LoadBalancerTest extends ScalaTestSupport {
   
+  @Test
   def testSimpleTrottler = {
     "mock:a" expect { _.received("message 1", "message 4") } 
     "mock:b" expect { _.received("message 2", "message 5") }

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopCopyTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopCopyTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopCopyTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopCopyTest.scala Mon Nov 28 15:16:45 2011
@@ -1,5 +1,3 @@
-package org.apache.camel.scala.dsl
-
 /**
  * Licensed to the Apache Software Foundation (ASF) under one or more
  * contributor license agreements.  See the NOTICE file distributed with
@@ -16,6 +14,9 @@ package org.apache.camel.scala.dsl
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
+package org.apache.camel.scala.dsl
+
+import org.junit.Test
 import builder.RouteBuilder
 
 /**
@@ -23,6 +24,7 @@ import builder.RouteBuilder
  */
 class LoopCopyTest extends ScalaTestSupport {
 
+  @Test
   def testLoopCopy() {
       getMockEndpoint("mock:loop").expectedBodiesReceived("AB", "AB", "AB")
       getMockEndpoint("mock:result").expectedBodiesReceived("AB")

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopNoCopyTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopNoCopyTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopNoCopyTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/LoopNoCopyTest.scala Mon Nov 28 15:16:45 2011
@@ -1,5 +1,3 @@
-package org.apache.camel.scala.dsl
-
 /**
  * Licensed to the Apache Software Foundation (ASF) under one or more
  * contributor license agreements.  See the NOTICE file distributed with
@@ -16,6 +14,9 @@ package org.apache.camel.scala.dsl
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
+package org.apache.camel.scala.dsl
+
+import org.junit.Test
 import builder.RouteBuilder
 
 /**
@@ -23,6 +24,7 @@ import builder.RouteBuilder
  */
 class LoopNoCopyTest extends ScalaTestSupport {
 
+  @Test
   def testLoopNoCopy() {
       getMockEndpoint("mock:loop").expectedBodiesReceived("AB", "ABB", "ABBB")
       getMockEndpoint("mock:result").expectedBodiesReceived("ABBB")

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/MulticastTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/MulticastTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/MulticastTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/MulticastTest.scala Mon Nov 28 15:16:45 2011
@@ -17,6 +17,7 @@
 package org.apache.camel
 package scala.dsl
 
+import org.junit.Test
 import builder.{RouteBuilderSupport, RouteBuilder}
 import org.apache.camel.processor.MulticastParallelTest
 

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/OnExceptionTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/OnExceptionTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/OnExceptionTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/OnExceptionTest.scala Mon Nov 28 15:16:45 2011
@@ -19,7 +19,8 @@ package org.apache.camel.scala.dsl
 import builder.{RouteBuilderSupport, RouteBuilder}
 import org.apache.camel.Exchange
 
-import junit.framework.Assert.{assertEquals, assertTrue}
+import org.junit.Assert.{assertEquals, assertTrue}
+import org.junit.Test
 import org.apache.camel.processor.onexception._
 
 /**
@@ -73,6 +74,7 @@ class SOnExceptionRetryUntilWithDefaultE
 
   var invoked = 0
 
+  @Test
   def testRetryUntil = {
     val out = template.requestBody("direct:start", "Hello World");
     assertEquals("Sorry", out);

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineAndMulticastTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineAndMulticastTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineAndMulticastTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineAndMulticastTest.scala Mon Nov 28 15:16:45 2011
@@ -17,12 +17,17 @@
 package org.apache.camel.scala.dsl;
  
 import builder.RouteBuilder
+import org.junit.Test
 
 class PipelineAndMulticastTest extends ScalaTestSupport {
 
+  @Test
   def testArrowRoute = testRoute("direct:a", "mock:c", "mock:a", "mock:b")
+  @Test
   def testToRoute = testRoute("direct:d", "mock:f", "mock:d", "mock:e")
+  @Test
   def testArrowBlockRoute = testRoute("direct:g", "mock:i", "mock:g", "mock:h")
+  @Test
   def testToBlockRoute = testRoute("direct:j", "mock:l", "mock:j", "mock:k")
 
   def testRoute(from: String, end: String, multis: String*) = {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineRouteBuilderTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineRouteBuilderTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineRouteBuilderTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineRouteBuilderTest.scala Mon Nov 28 15:16:45 2011
@@ -17,12 +17,16 @@
 package org.apache.camel.scala.dsl;
 
 import builder.RouteBuilder
- 
-class PipelineRouteBuilderTest extends ScalaTestSupport {
+import org.junit.Test
 
+class PipelineRouteBuilderTest extends ScalaTestSupport {
+  @Test
   def testPipelineWithArrows() = testPipeline("direct:a", "mock:a", "mock:b")
+  @Test
   def testPipelineWithTos() = testPipeline("direct:c", "mock:c", "mock:d")
+  @Test
   def testPipelineBlockWithArrows() = testPipeline("direct:e", "mock:e", "mock:f")
+  @Test
   def testPipelineBlockWithTos() = testPipeline("direct:g", "mock:g", "mock:h")
 
   def testPipeline(from: String, to: String*) = {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/PipelineTest.scala Mon Nov 28 15:16:45 2011
@@ -19,7 +19,8 @@ package org.apache.camel.scala.dsl
 import builder.RouteBuilder
 import org.apache.camel.Exchange
 import javax.activation.{FileDataSource, DataHandler}
-import junit.framework.Assert.assertNotNull
+import org.junit.Test
+import org.junit.Assert.assertNotNull
 
 /**
  * Unit tests for the explicit 'pipeline' DSL keyword 
@@ -49,6 +50,7 @@ class SPipelineTest extends ScalaTestSup
     out.removeHeader("test") : Unit
   }  
 
+  @Test
   def testIncrementSimple = {
     "mock:result" expect { _.received(new java.lang.Integer(4))}
     test {
@@ -56,6 +58,7 @@ class SPipelineTest extends ScalaTestSup
     }
   }
 
+  @Test
   def testIncrementBlock = {
     "mock:result" expect { _.received(new java.lang.Integer(4))}
     test {
@@ -63,6 +66,7 @@ class SPipelineTest extends ScalaTestSup
     }
   }
 
+  @Test
   def testExplicitPipeline = {
     test {
       "direct:start" ! "Hello world"

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RecipientListRouteTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RecipientListRouteTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RecipientListRouteTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RecipientListRouteTest.scala Mon Nov 28 15:16:45 2011
@@ -17,23 +17,27 @@
 package org.apache.camel.scala
 package dsl
 
+import org.junit.Test
 import builder.RouteBuilder
 import test.{Adult, Toddler, Envelope}
  
 class RecipientListRouteTest extends ScalaTestSupport {
   
+  @Test
   def testRecipientList = {
     "mock:a" expect {_.count = 1}
     "direct:a" ! ("send this message to mock:a", "send this message to mock:z")
     "mock:a" assert()
   }
   
+  @Test
   def testRecipientListWithPatternMatching = {
     "mock:playgarden" expect {_.count = 1}
     "direct:b" ! (new Adult("Gert"), new Toddler("Ewan"))
     "mock:playgarden" assert()    
   }
   
+  @Test
   def testRecipientListWithJXPath = {
     "mock:c" expect {_.count = 2}
     "mock:d" expect {_.count = 1}

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ResequencerTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ResequencerTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ResequencerTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ResequencerTest.scala Mon Nov 28 15:16:45 2011
@@ -15,7 +15,8 @@
  * limitations under the License.
  */
 package org.apache.camel.scala.dsl;
- 
+
+import org.junit.Test
 import org.w3c.dom.Document
 import builder.RouteBuilder
 
@@ -24,6 +25,7 @@ import builder.RouteBuilder
  */
 class ResequencerTest extends ScalaTestSupport {
   
+  @Test
   def testSimpleResequencer = {
     "mock:a" expect { _.received("message 1", "message 2", "message 3", "message 4", "message 5") } 
     test {
@@ -31,6 +33,7 @@ class ResequencerTest extends ScalaTestS
     }
   }
   
+  @Test
   def testBlockResequencer = {
     "mock:b" expect (_.received("message 5", "message 1", "message 3", "message 2", "message 4"))
     "mock:c" expect (_.received("message 1", "message 2", "message 3", "message 4", "message 5"))
@@ -39,6 +42,7 @@ class ResequencerTest extends ScalaTestS
     }
   }
   
+  @Test
   def testBatchResequencer = {
     "mock:d" expect (_.received("message 5", "message 1", "message 3", "message 2"))
     "mock:e" expect (_.count = 0)

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RollbackTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RollbackTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RollbackTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RollbackTest.scala Mon Nov 28 15:16:45 2011
@@ -16,7 +16,8 @@
  */
 package org.apache.camel
 package scala.dsl
- 
+
+import org.junit.Test
 import builder.RouteBuilder
 import junit.framework.Assert._
 
@@ -27,6 +28,7 @@ class RollbackTest extends ScalaTestSupp
   
   var handled = false;
   
+  @Test
   def testSimple = {
     test {
       try {
@@ -40,6 +42,7 @@ class RollbackTest extends ScalaTestSupp
     }
   }
   
+  @Test
   def testBlock = {
     "mock:b" expect { _.count = 2 }
     "mock:ok" expect { _.count = 1 }

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteErrorHandlerTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteErrorHandlerTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteErrorHandlerTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteErrorHandlerTest.scala Mon Nov 28 15:16:45 2011
@@ -16,12 +16,14 @@
  */
 package org.apache.camel.scala.dsl
 
+import org.junit.Test
 import builder.RouteBuilder
 import org.apache.camel.Exchange
 import org.junit.Assert._
 
 class RouteErrorHandlerTest extends ScalaTestSupport {
 
+  @Test
   def testRouteHandlerActive {
     "mock:deadLetter" expect {
       _.expectedMessageCount(1)
@@ -33,6 +35,7 @@ class RouteErrorHandlerTest extends Scal
 
   }
 
+  @Test
   def testContextHandlerStillActive {
     try {
       test {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteIdTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteIdTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteIdTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/RouteIdTest.scala Mon Nov 28 15:16:45 2011
@@ -18,10 +18,12 @@ package org.apache.camel
 package scala.dsl
 
 import builder.RouteBuilder
-import junit.framework.Assert.assertEquals
+import org.junit.Test
+import org.junit.Assert.assertEquals
 
 class RouteIdTest extends ScalaTestSupport {
 
+  @Test
   def testRouteA = {
     "mock:a" expect { _.expectedMessageCount(1)}
 
@@ -34,6 +36,7 @@ class RouteIdTest extends ScalaTestSuppo
     assertEquals("route-a", context.getRouteDefinitions.get(0).getId());
   }
 
+  @Test
   def testRouteB = {
     "mock:b" expect { _.expectedMessageCount(1)}
 

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ScalaTestSupport.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ScalaTestSupport.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ScalaTestSupport.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ScalaTestSupport.scala Mon Nov 28 15:16:45 2011
@@ -18,12 +18,12 @@ package org.apache.camel
 package scala
 package dsl
 
-import org.apache.camel.ContextTestSupport
 import org.apache.camel.component.mock.MockEndpoint
+import org.apache.camel.test.junit4.CamelTestSupport
 import builder.{RouteBuilder,RouteBuilderSupport}
 import _root_.scala.collection.mutable.ArrayBuffer
 
-abstract class ScalaTestSupport extends ContextTestSupport with RouteBuilderSupport with Preamble {
+abstract class ScalaTestSupport extends CamelTestSupport with RouteBuilderSupport with Preamble {
   
   implicit def stringToUri(uri:String) = new RichTestUri(uri, this)
   implicit def mockWrapper(endpoint: MockEndpoint) = new RichMockEndpoint(endpoint)

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetBodyTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetBodyTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetBodyTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetBodyTest.scala Mon Nov 28 15:16:45 2011
@@ -18,16 +18,21 @@ package org.apache.camel.scala.dsl;
  
 import builder.RouteBuilder
 import org.apache.camel.scala.test.Cat
+import org.junit.Test
 
 /**
  * Test for setting the message body from the Scala DSL
  */
 class SetBodyTest extends ScalaTestSupport {
 
+  @Test
   def testSimpleSetBody() = doTestConstant("direct:a", "mock:a")
+  @Test
   def testBlockSetBody() = doTestConstant("direct:b", "mock:b")
   
+  @Test
   def testSimpleExpression() = doTestExpression("direct:c", "mock:c")
+  @Test
   def testBodyExpression() = doTestExpression("direct:d", "mock:d")
   
   

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetExchangePatternTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetExchangePatternTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetExchangePatternTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetExchangePatternTest.scala Mon Nov 28 15:16:45 2011
@@ -16,19 +16,25 @@
  */
 package org.apache.camel
 package scala.dsl
- 
-import builder.RouteBuilder
-import junit.framework.Assert.assertEquals
+
 import org.apache.camel.ExchangePattern._
+import builder.RouteBuilder
+import org.junit.Test
+import org.junit.Assert.assertEquals
+
 
 /**
  * Test for setting the ExchangePattern 
  */
 class SetExchangePatternTest extends ScalaTestSupport {
 
+  @Test
   def testSimpleInOnly() = doTest("direct:a", "mock:a", InOnly)
+  @Test
   def testBlockInOnly() = doTest("direct:b", "mock:b", InOnly)
+  @Test
   def testSimpleInOut() = doTest("direct:c", "mock:c", InOut)
+  @Test
   def testBlockInOut() = doTest("direct:d", "mock:d", InOut)
   
   

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetHeaderTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetHeaderTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetHeaderTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SetHeaderTest.scala Mon Nov 28 15:16:45 2011
@@ -19,16 +19,21 @@ package dsl;
  
 import builder.RouteBuilder
 import org.apache.camel.scala.test.Cat
+import org.junit.Test
 
 /**
  * Test for setting the message header from the Scala DSL
  */
 class SetHeaderTest extends ScalaTestSupport {
 
+  @Test
   def testSimpleSetBody() = doTestConstant("direct:a", "mock:a")
+  @Test
   def testBlockSetBody() = doTestConstant("direct:b", "mock:b")
   
+  @Test
   def testSimpleExpression() = doTestExpression("direct:c", "mock:c")
+  @Test
   def testBodyExpression() = doTestExpression("direct:d", "mock:d")
   
   

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SimpleBeanTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SimpleBeanTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SimpleBeanTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SimpleBeanTest.scala Mon Nov 28 15:16:45 2011
@@ -19,12 +19,14 @@ package scala.dsl
  
 import builder.RouteBuilder
 import org.apache.camel.scala.test.CartoonService
+import org.junit.Test
 
 /**
  * Test for bean support in simple Scala DSL expressions
  */
 class SimpleBeanTest extends ScalaTestSupport {
 
+  @Test
   def testSimpleObject() = {
     "mock:a" expect {_.received("Lucky Luke rides Jolly Jumper")}
     test {
@@ -32,6 +34,7 @@ class SimpleBeanTest extends ScalaTestSu
     }
   }
   
+  @Test
   def testSimpleClass() = {
     "mock:b" expect {_.received("Batman drives the batmobile")}
     test {
@@ -39,6 +42,7 @@ class SimpleBeanTest extends ScalaTestSu
     }
   }
   
+  @Test
   def testSimpleRef() = {
     "mock:c" expect {_.received("Aladin flies a carpet")}
     test {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SplitterRouteBuilderTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SplitterRouteBuilderTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SplitterRouteBuilderTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/SplitterRouteBuilderTest.scala Mon Nov 28 15:16:45 2011
@@ -19,18 +19,21 @@ package scala.dsl
  
 import builder.RouteBuilder
 import org.w3c.dom.Document
+import org.junit.Test
 
 /**
  * Test case for Splitter
  */
 class SplitterRouteBuilderTest extends ScalaTestSupport {
 
+  @Test
   def testSimpleSplitter = {
     "mock:a" expect { _.count = 3}
     "direct:a" ! <persons><person id="1"/><person id="2"/><person id="3"/></persons>
     "mock:a" assert()
   }
   
+  @Test
   def testBlockSplitter = {
     "mock:b" expect { _.count = 3}
     "mock:c" expect { _.count = 3}

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ThrottlerTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ThrottlerTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ThrottlerTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/ThrottlerTest.scala Mon Nov 28 15:16:45 2011
@@ -18,19 +18,22 @@ package org.apache.camel
 package scala.dsl
  
 import builder.RouteBuilder
+import org.junit.Test
 
 /**
  * Test case for message throttler
  */
 class ThrottlerTest extends ScalaTestSupport {
   
+  @Test
   def testSimpleThrottler = {
     "mock:a" expect { _.count = 3 } 
     "mock:a" expect { _.setResultWaitTime(1000) }
     for (id <- 1 to 6) "seda:a" ! id   
     "mock:a" assert()
   }
-  
+ 
+  @Test
   def testBlockThrottler = {
     "mock:b" expect { _.count = 6 }
     "mock:c" expect { _.count = 3 } 

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/TryCatchFinallyTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/TryCatchFinallyTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/TryCatchFinallyTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/TryCatchFinallyTest.scala Mon Nov 28 15:16:45 2011
@@ -18,7 +18,8 @@ package org.apache.camel
 package scala.dsl;
  
 import builder.RouteBuilder
-import junit.framework.Assert._
+import org.junit.Test
+import org.junit.Assert._
 
 /**
  * Test case for try (attempt) - catch (handle) - finally (ensure)
@@ -27,6 +28,7 @@ class TryCatchFinallyTest extends ScalaT
   
   var handled = false;
   
+  @Test
   def testTryCatchFinally = {
     "mock:a" expect { _.count = 1 }
     "mock:b" expect { _.count = 1 }

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/WiretapTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/WiretapTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/WiretapTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/WiretapTest.scala Mon Nov 28 15:16:45 2011
@@ -19,16 +19,21 @@ package scala.dsl
  
 import org.apache.camel.scala.test.Adult
 import builder.RouteBuilder
+import org.junit.Test
 
 /**
  * Test case for wiretap
  */
 class WiretapTest extends ScalaTestSupport {
   
+  @Test
   def testSimpleTap = doTestWiretap("direct:a", "mock:a")
+  @Test
   def testBlockTap = doTestWiretap("direct:b", "mock:b")
   
+  @Test
   def testSimpleTapWithBody = doTestWiretapWithBody("direct:c", "mock:c")
+  @Test
   def testBlockTapWithBody = doTestWiretapWithBody("direct:d", "mock:d")
   
   def doTestWiretap(from: String, to: String) = {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/XPathContentBasedRouterTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/XPathContentBasedRouterTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/XPathContentBasedRouterTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/XPathContentBasedRouterTest.scala Mon Nov 28 15:16:45 2011
@@ -17,12 +17,14 @@
 package org.apache.camel.scala.dsl
 
 import builder.RouteBuilder
+import org.junit.Test
 
 /**
  * Content Based Router test with XPath expressions
  */
 class XPathContentBasedRouterTest extends ScalaTestSupport {
 
+  @Test
   def testXPathContentBasedRouter = {
     "mock:english" expect {_.expectedBodiesReceived("<hello/>")}
     "mock:dutch" expect {_.expectedBodiesReceived("<hallo/>")}

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/RouteBuilderUnwrapTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/RouteBuilderUnwrapTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/RouteBuilderUnwrapTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/RouteBuilderUnwrapTest.scala Mon Nov 28 15:16:45 2011
@@ -18,10 +18,11 @@ package org.apache.camel.scala.dsl.build
  
 import org.apache.camel.scala.Wrapper
 import org.apache.camel.scala.test.{Person,Adult}
-import junit.framework.TestCase
-import junit.framework.Assert._
+import org.junit.Assert
+import org.junit.Assert._
+import org.junit.Test
 
-class RouteBuilderUnwrapTest extends TestCase {
+class RouteBuilderUnwrapTest extends Assert {
 
   def builder = new RouteBuilder {
     
@@ -37,7 +38,7 @@ class RouteBuilderUnwrapTest extends Tes
     
   }
 
-  
+  @Test
   def testUnwrapWhenNecessary() = builder.testUnwrap
   
   class PersonWrapper extends Wrapper[Person] {

Modified: camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/scan/DiscoverRouteBuilderTest.scala
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/scan/DiscoverRouteBuilderTest.scala?rev=1207287&r1=1207286&r2=1207287&view=diff
==============================================================================
--- camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/scan/DiscoverRouteBuilderTest.scala (original)
+++ camel/trunk/components/camel-scala/src/test/scala/org/apache/camel/scala/dsl/builder/scan/DiscoverRouteBuilderTest.scala Mon Nov 28 15:16:45 2011
@@ -19,14 +19,16 @@ package org.apache.camel.scala.dsl.build
 import org.apache.camel.CamelContext
 import org.apache.camel.component.mock.MockEndpoint
 import org.springframework.context.support.ClassPathXmlApplicationContext
-import junit.framework.TestCase
-import junit.framework.Assert._
+import org.junit.Assert
+import org.junit.Assert._
+import org.junit.Test
 
 /**
  * Test to make sure that Scala DSL RouteBuilders can be discovered from the classpath
  */
-class DiscoverRouteBuilderTest extends TestCase {
+class DiscoverRouteBuilderTest extends Assert {
   
+  @Test
   def testDiscovery = {
     val spring = new ClassPathXmlApplicationContext("org/apache/camel/scala/dsl/builder/scan/scan-camel-context.xml")
     val camel = spring.getBean("myCamel").asInstanceOf[CamelContext]



Mime
View raw message