camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject svn commit: r1376088 - in /camel/trunk/components: camel-test/src/main/java/org/apache/camel/test/TestSupport.java camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java
Date Wed, 22 Aug 2012 15:03:50 GMT
Author: davsclaus
Date: Wed Aug 22 15:03:50 2012
New Revision: 1376088

URL: http://svn.apache.org/viewvc?rev=1376088&view=rev
Log:
Added assertFileNotExists to test kit

Modified:
    camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java
    camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java
    camel/trunk/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java

Modified: camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java?rev=1376088&r1=1376087&r2=1376088&view=diff
==============================================================================
--- camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java
(original)
+++ camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java
Wed Aug 22 15:03:50 2012
@@ -504,6 +504,14 @@ public abstract class TestSupport extend
     }
 
     /**
+     * To be used to check is a file is <b>not</b> found in the file system
+     */
+    public static void assertFileNotExists(String filename) {
+        File file = new File(filename).getAbsoluteFile();
+        assertFalse("File " + filename + " should not exist", file.exists());
+    }
+
+    /**
      * Is this OS the given platform.
      * <p/>
      * Uses <tt>os.name</tt> from the system properties to determine the OS.

Modified: camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java?rev=1376088&r1=1376087&r2=1376088&view=diff
==============================================================================
--- camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java
(original)
+++ camel/trunk/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java
Wed Aug 22 15:03:50 2012
@@ -491,6 +491,14 @@ public abstract class TestSupport extend
     }
 
     /**
+     * To be used to check is a file is <b>not</b> found in the file system
+     */
+    public static void assertFileNotExists(String filename) {
+        File file = new File(filename).getAbsoluteFile();
+        assertFalse("File " + filename + " should not exist", file.exists());
+    }
+
+    /**
      * Is this OS the given platform.
      * <p/>
      * Uses <tt>os.name</tt> from the system properties to determine the OS.

Modified: camel/trunk/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java?rev=1376088&r1=1376087&r2=1376088&view=diff
==============================================================================
--- camel/trunk/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java
(original)
+++ camel/trunk/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java
Wed Aug 22 15:03:50 2012
@@ -479,6 +479,14 @@ public abstract class TestSupport extend
     }
 
     /**
+     * To be used to check is a file is <b>not</b> found in the file system
+     */
+    public static void assertFileNotExists(String filename) {
+        File file = new File(filename).getAbsoluteFile();
+        assertFalse(file.exists(), "File " + filename + " should not exist");
+    }
+
+    /**
      * Is this OS the given platform.
      * <p/>
      * Uses <tt>os.name</tt> from the system properties to determine the OS.



Mime
View raw message