PathCost cost = new PathCost(password);
cost.addPattern(new PasswordPattern(6, 3, "abc", 100, "test pattern"));
cost.addPattern(new PasswordPattern(3, 3, "abc", 100, "test pattern"));
cost.addPattern(new PasswordPattern(0, 3, "abc", 100, "test pattern"));
RepeatingPatternFinder instance = new RepeatingPatternFinder();
PathCost result = instance.process(cost, password);
assertEquals(100, (int) result.getTotalCost());
List<PasswordPattern> pattList = result.getPath();
assertEquals(3, pattList.size());
assertEquals(RepeatingPatternFinder.DUPLICATE_PATTERN, pattList.get(1).getName());
assertEquals(RepeatingPatternFinder.DUPLICATE_PATTERN, pattList.get(2).getName());