File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change 1414def is_stochastic (players , noise ):
1515 """Determines if a match is stochastic -- true if there is noise or if any
1616 of the players involved is stochastic."""
17- return noise or any (Classifiers ["stochastic" ]( p ) for p in players )
17+ return noise or any (map ( Classifiers ["stochastic" ], players ) )
1818
1919
2020class Match (object ):
Original file line number Diff line number Diff line change 1717from axelrod .player import Player
1818
1919
20- class TestTitForTat (Player ):
20+ class TitForTatWithEmptyClassifier (Player ):
2121 """
2222 Same name as TitForTat, but with empty classifier.
2323 """
@@ -65,7 +65,7 @@ def test_key_error_on_uknown_classifier(self):
6565 Classifiers ["invalid_key" ](axl .TitForTat )
6666
6767 def test_will_lookup_key_in_dict (self ):
68- self .assertEqual (Classifiers ["memory_depth" ](TestTitForTat ), 1 )
68+ self .assertEqual (Classifiers ["memory_depth" ](TitForTatWithEmptyClassifier ), 1 )
6969
7070 def test_known_classifiers (self ):
7171 # A set of dimensions that are known to have been fully applied
You can’t perform that action at this time.
0 commit comments