Exemplo n.º 1
0
 def test_just_applicative_3(self):
     a = Just.pure(lambda x, y: x+y).apply(Just(42)).apply(Nothing())
     self.assertEqual(a, Nothing())
Exemplo n.º 2
0
 def test_just_applicative_3(self):
     a = Just.pure(lambda x, y: x+y).apply(Just(42)).apply(Nothing())
     self.assertEquals(a, Nothing())
Exemplo n.º 3
0
 def test_just_applicative_1(self):
     a = Just.pure(lambda x, y: x + y).apply(Just(2)).apply(Just(40))
     self.assertNotEquals(a, Nothing())
     self.assertEquals(a, Just(42))