File subsubconfigDir = writeDirectory(subconfigDir, "subsubconfig");
writeFile(subsubconfigDir, "subsubone.config", "subsubconfig 1 file");
Configuration config = new Configuration();
config.put(new PropertySimple(SnapshotReport.PROP_BASE_DIRECTORY, baseDir.getAbsolutePath()));
config.put(new PropertySimple(SnapshotReport.PROP_SNAPSHOT_CONFIG_FILES, "true"));
config.put(new PropertySimple(SnapshotReport.PROP_SNAPSHOT_LOG_FILES, "true"));
config.put(new PropertySimple(SnapshotReport.PROP_SNAPSHOT_DATA_FILES, "true"));
config.put(new PropertySimple(SnapshotReport.PROP_SNAPSHOT_ADDITIONAL_FILES, "true"));
config.put(new PropertySimple(SnapshotReport.PROP_CONFIG_DIRECTORY, configDir.getName())); // relative path
config.put(new PropertySimple(SnapshotReport.PROP_LOG_DIRECTORY, logDir.getName())); // relative path
config.put(new PropertySimple(SnapshotReport.PROP_DATA_DIRECTORY, dataDir.getName())); // relative path
config.put(new PropertySimple(SnapshotReport.PROP_CONFIG_REGEX, ".*\\.config"));
config.put(new PropertySimple(SnapshotReport.PROP_LOG_REGEX, ".*\\.log"));
config.put(new PropertySimple(SnapshotReport.PROP_DATA_REGEX, ".*\\.dat"));
config.put(new PropertySimple(SnapshotReport.PROP_CONFIG_RECURSIVE, "false"));
config.put(new PropertySimple(SnapshotReport.PROP_LOG_RECURSIVE, "false"));
config.put(new PropertySimple(SnapshotReport.PROP_DATA_RECURSIVE, "false"));
String dir1 = additionalDir1.getName();
PropertyList additionalList = new PropertyList(SnapshotReport.PROP_ADDITIONAL_FILES_LIST);
PropertyMap additionalFiles1 = new PropertyMap("map");
additionalFiles1.put(new PropertySimple(SnapshotReport.PROP_ADDITIONAL_FILES_DIRECTORY, dir1));
additionalFiles1.put(new PropertySimple(SnapshotReport.PROP_ADDITIONAL_FILES_REGEX, ".*\\.txt"));
additionalFiles1.put(new PropertySimple(SnapshotReport.PROP_ADDITIONAL_FILES_RECURSIVE, "false"));
additionalFiles1.put(new PropertySimple(SnapshotReport.PROP_SNAPSHOT_ADDITIONAL_FILES, "true"));
config.put(additionalList);
additionalList.add(additionalFiles1);
SnapshotReport report = new SnapshotReport("test-snapshot", "some desc", config);
File snapshot = report.generate();