Author: davsclaus
Date: Wed Aug 22 15:11:06 2012
New Revision: 1376091
URL: http://svn.apache.org/viewvc?rev=1376091&view=rev
Log:
Added assertFileNotExists to test kit
Modified:
camel/branches/camel-2.10.x/ (props changed)
camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java
camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java
camel/branches/camel-2.10.x/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java
Propchange: camel/branches/camel-2.10.x/
------------------------------------------------------------------------------
Merged /camel/trunk:r1376088
Propchange: camel/branches/camel-2.10.x/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.
Modified:
camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java
URL:
http://svn.apache.org/viewvc/camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java?rev=1376091&r1=1376090&r2=1376091&view=diff
==============================================================================
---
camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java
(original)
+++
camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java
Wed Aug 22 15:11:06 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/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java
URL:
http://svn.apache.org/viewvc/camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java?rev=1376091&r1=1376090&r2=1376091&view=diff
==============================================================================
---
camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java
(original)
+++
camel/branches/camel-2.10.x/components/camel-test/src/main/java/org/apache/camel/test/junit4/TestSupport.java
Wed Aug 22 15:11:06 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/branches/camel-2.10.x/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java
URL:
http://svn.apache.org/viewvc/camel/branches/camel-2.10.x/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java?rev=1376091&r1=1376090&r2=1376091&view=diff
==============================================================================
---
camel/branches/camel-2.10.x/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java
(original)
+++
camel/branches/camel-2.10.x/components/camel-testng/src/main/java/org/apache/camel/testng/TestSupport.java
Wed Aug 22 15:11:06 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.