Skip to content

Commit

Permalink
Minor test helper improvement (to avoid issues with concurrent direct…
Browse files Browse the repository at this point in the history
…ory creation on file system and improve error reporting)
  • Loading branch information
asoldano committed Jul 31, 2015
1 parent f32e95f commit 95ae0c2
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -421,9 +421,9 @@ public static File assertArchiveDirExists()
if (testArchiveDir == null)
throw new IllegalArgumentException("Cannot create archive - system property '"
+ JBossWSTestHelper.SYSPROP_TEST_ARCHIVE_DIRECTORY + "' not set.");
if (!archiveDir.mkdirs())
if (!archiveDir.mkdirs() && !archiveDir.exists())
throw new IllegalArgumentException("Cannot create archive - can not create test archive directory '"
+ archiveDir.getAbsolutePath() + "' not set.");
+ archiveDir.getAbsolutePath() + "'");
}
return archiveDir;
}
Expand Down

0 comments on commit 95ae0c2

Please sign in to comment.