mirror of
https://github.com/internetarchive/heritrix3.git
synced 2026-07-19 14:07:05 +00:00
Fix selftest failures where empty 'profile' directory may not exist (eg git)
* SelfTestBase
only copy profile directory if it exists
This commit is contained in:
@@ -86,7 +86,10 @@ public abstract class SelfTestBase extends TmpDirTestCase {
|
||||
// Copy the selftest's profile in the project directory to the
|
||||
// default profile in the temporary Heritrix directory.
|
||||
File tmpDefProfile = new File(tmpJobs, "selftest-job");
|
||||
org.apache.commons.io.FileUtils.copyDirectory(new File(src, "profile"), tmpDefProfile);
|
||||
File profileTemplate = new File(src, "profile");
|
||||
if(profileTemplate.exists()) {
|
||||
org.apache.commons.io.FileUtils.copyDirectory(profileTemplate, tmpDefProfile);
|
||||
}
|
||||
|
||||
// Start up a Jetty that serves the selftest's content directory.
|
||||
startHttpServer();
|
||||
|
||||
Reference in New Issue
Block a user