@@ -25,8 +25,7 @@ public void intersection_monoid_test() {
25
25
Monoid <Set <Integer >> intersectionMonoid = Monoid .setIntersectionMonoid (integersBounded , Enumerator .intEnumerator , Ord .intOrd );
26
26
Set <Integer > first = Set .set (Ord .intOrd , 1 , 2 , 3 , 4 );
27
27
Set <Integer > second = Set .set (Ord .intOrd , 3 , 4 , 5 , 6 );
28
- Set <Integer > zero = intersectionMonoid .zero ();
29
- Set <Integer > actual = intersectionMonoid .sum (intersectionMonoid .sum (zero , first ), second );
28
+ Set <Integer > actual = intersectionMonoid .sum (first , second );
30
29
assertThat (actual , is (Set .set (Ord .intOrd , 3 , 4 )));
31
30
}
32
31
@@ -35,8 +34,7 @@ public void union_monoid_test() {
35
34
Monoid <Set <Integer >> unionMonoid = Monoid .setMonoid (Ord .intOrd );
36
35
Set <Integer > first = Set .set (Ord .intOrd , 1 , 2 , 3 , 4 );
37
36
Set <Integer > second = Set .set (Ord .intOrd , 3 , 4 , 5 , 6 );
38
- Set <Integer > zero = unionMonoid .zero ();
39
- Set <Integer > actual = unionMonoid .sum (unionMonoid .sum (zero , first ), second );
37
+ Set <Integer > actual = unionMonoid .sum (first , second );
40
38
assertThat (actual , is (Set .set (Ord .intOrd , 1 , 2 , 3 , 4 , 5 , 6 )));
41
39
}
42
40
0 commit comments