def test_monoid_associativity(self, a, b, c):
     l1 = MyHashMap(vItem=a)
     l2 = MyHashMap(vItem=b)
     l3 = MyHashMap(vItem=c)
     aa = l1.mconcat(l1.mconcat(l1, l2), l3).to_list()
     bb = l1.mconcat(l1, l1.mconcat(l2, l3)).to_list()
     self.assertEqual(aa.sort(), bb.sort())
 def test_monoid_identity(self, lst):
     a = MyHashMap(vItem=[1, 2])
     a.from_list(lst)
     self.assertEqual(a.mconcat(a.mempty(), a), a)
     self.assertEqual(a.mconcat(a, a.mempty()), a)