ResourcePersister persister = new DefaultResourcePersister(getSession(), mock(ResourcePermissions.class), snapshotCache, resourceCache);
persister.saveProject(multiModuleProject, null);
persister.saveProject(moduleA, multiModuleProject);
persister.saveProject(moduleB, multiModuleProject);
persister.saveProject(moduleB1, moduleB);
Resource file = File.create("src/main/java/org/Foo.java").setEffectiveKey("b1:src/main/java/org/Foo.java");
file.getParent().setEffectiveKey("b1:src/main/java/org");
persister.saveResource(moduleB1, file.getParent());
persister.saveResource(moduleB1, file, file.getParent());
checkTables("shouldSaveNewMultiModulesProject",
new String[] {"build_date", "created_at", "authorization_updated_at", "uuid", "project_uuid", "module_uuid", "module_uuid_path"}, "projects", "snapshots");
// Need to enable snapshot to make resource visible using ComponentMapper