@Test
public void withMatchRule() {

	MatchRule rule = MatchRule.withPattern("abc");
	MatchRule rule2 = MatchRule.withPattern("abc2");
	Category category = new Category("a name");
	Category category2 = category.withMatchRule(rule);
	assertNotNull(category2);
	assertNotSame(category, category2);
	assertEquals(category.getName(), category2.getName());
	assertEquals(ImmutableList.of(), category.getMatchRules());
	assertEquals(ImmutableList.of(rule), category2.getMatchRules());
	assertEquals(ImmutableList.of(rule, rule2), category2.withMatchRule(rule2).getMatchRules());
}