示例#1
0
 def test_something(self):
     value = Maybe(1)
     assert value.otherwise() == 1
示例#2
0
 def test_none(self):
     value = Maybe(None)
     assert value.otherwise(1) is None
示例#3
0
 def test_nothing(self):
     value = Maybe(EMPTY)
     assert value.otherwise() is None