private void assertPatternValues(Pattern pattern, String value, Map<String,String> expectedValues) {
assertTrue(matches(pattern, value));
Collection<Expression> expressions = new HashSet<Expression>();
for (String attributeName: expectedValues.keySet()) {
String attributeValue = (String) expectedValues.get(attributeName);
Attribute attribute = SQL.parseAttribute(attributeName);
expressions.add(Equality.create(
new AttributeExpr(attribute),
new Constant(attributeValue, attribute)));
}
Expression expr = Conjunction.create(expressions);