app.getRoles().create(adminRole);
app.getProjects().addUserRole(project.getId(), admin.getId(), adminRole.getId());
// Test export/import
System.out.println(new Loader().export(app.getCache()));
try
{
ByteArrayOutputStream baos = new ByteArrayOutputStream();
new Loader().export(app.getCache(), baos);
ByteArrayInputStream bios = new ByteArrayInputStream(baos.toByteArray());
app.getCache().clear();
new Loader().importStore(bios, app.getCache());
}
catch (Exception e)
{
e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.
}