Skip to content
Snippets Groups Projects
Commit 3dcfad66 authored by felmer's avatar felmer
Browse files

weakend exception message assertion because of differences between Linux and Windows

SVN: 2088
parent b6ade906
No related branches found
No related tags found
No related merge requests found
...@@ -95,7 +95,8 @@ public class FileUtilitiesTest ...@@ -95,7 +95,8 @@ public class FileUtilitiesTest
{ {
Throwable cause = e.getCause(); Throwable cause = e.getCause();
assertTrue(cause instanceof IOException); assertTrue(cause instanceof IOException);
assertEquals(dir + " (Access is denied)", cause.getMessage()); String message = cause.getMessage();
assertTrue("Exception message not as expected: " + message, cause.getMessage().startsWith(dir.toString()));
} }
} }
...@@ -113,7 +114,8 @@ public class FileUtilitiesTest ...@@ -113,7 +114,8 @@ public class FileUtilitiesTest
{ {
Throwable cause = e.getCause(); Throwable cause = e.getCause();
assertTrue(cause instanceof IOException); assertTrue(cause instanceof IOException);
assertEquals(file + " (Access is denied)", cause.getMessage()); String message = cause.getMessage();
assertTrue("Exception message not as expected: " + message, cause.getMessage().startsWith(file.toString()));
} finally } finally
{ {
assert file.delete(); assert file.delete();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment