append("other_group_db = " + otherPolicyFile.getPath(), globalPolicyFile);
append("[groups]", otherPolicyFile);
append("other_group = malicious_role", otherPolicyFile);
append("[roles]", otherPolicyFile);
append("malicious_role = server=server1->db=customers->table=purchases->action=select", otherPolicyFile);
PolicyEngine policy = new SimplePolicyEngine(globalPolicyFile.getPath(), "server1");
ImmutableSet<String> permissions = policy.getPermissions(
Arrays.asList(new Authorizable[] {
new Server("server1"),
new Database("other_group_db")
}), Lists.newArrayList("other_group")).get("other_group");
Assert.assertTrue(permissions.toString(), permissions.isEmpty());