assertFalse(implies(new WebResourcePermission("/Test", "!"), permissions, null));
}
public void testExcludedConstraint() throws Exception {
WebApp webApp = parse("security/web3.xml");
WebAppInfoBuilder webAppInfoBuilder = new WebAppInfoBuilder(webApp, new DefaultWebAppInfoFactory());
webAppInfoBuilder.build();
SpecSecurityBuilder builder = new SpecSecurityBuilder(webAppInfoBuilder.getWebAppInfo());
ComponentPermissions permissions = builder.buildSpecSecurityConfig();
Permission p = new WebResourcePermission("/Test/Foo", "GET,POST");
assertTrue(implies(p, permissions, "Admin"));
assertFalse(implies(p, permissions, null));
p = new WebResourcePermission("/Test/Bar/Foo", "GET,POST");