// Setting of the workspace configuration
WorkspaceInfo ws = getCatalog().getWorkspaceByName("test");
assertNotNull(ws);
// Creation of new Settings to test
SettingsInfoImpl info = new SettingsInfoImpl();
// Setting of the metadata map if not present
if (info.getMetadata() == null) {
info.setMetadata(new MetadataMap());
}
// Selection of the metadata map
MetadataMap map = info.getMetadata();
// Addition of the key associated to the root directory
map.put(RESTUtils.ROOT_KEY, root);
// Associate the workspace to the settings
info.setWorkspace(ws);
// Add the new Settings
getGeoServer().add(info);
// Test of the input file
testFile(rootFile, "test", "usa2");
}