use of org.nhindirect.stagent.policy.impl.UniversalPolicyResolver in project nhin-d by DirectProject.
the class UniversalPolicyResolver_constructTest method testConstruct_singleExpression_assertAttributes.
public void testConstruct_singleExpression_assertAttributes() {
final PolicyExpression expression = mock(PolicyExpression.class);
final UniversalPolicyResolver resolver = new UniversalPolicyResolver(expression);
assertNotNull(resolver);
assertEquals(1, resolver.expressions.size());
assertEquals(expression, resolver.expressions.iterator().next());
}
use of org.nhindirect.stagent.policy.impl.UniversalPolicyResolver in project nhin-d by DirectProject.
the class UniversalPolicyResolver_constructTest method testConstruct_multipleExpressions_assertAttributes.
public void testConstruct_multipleExpressions_assertAttributes() {
final PolicyExpression expression1 = mock(PolicyExpression.class);
final PolicyExpression expression2 = mock(PolicyExpression.class);
final UniversalPolicyResolver resolver = new UniversalPolicyResolver(Arrays.asList(expression1, expression2));
assertNotNull(resolver);
assertEquals(2, resolver.expressions.size());
final Iterator<PolicyExpression> iter = resolver.expressions.iterator();
assertEquals(expression1, iter.next());
assertEquals(expression2, iter.next());
}
Aggregations