Skip to content

Commit 01bcf8f

Browse files
committed
Add round_robin as the default tournament_type value
1 parent 5a28e56 commit 01bcf8f

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

axelrod/tournament.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
class Tournament(object):
1414
game = Game()
1515

16-
def __init__(self, players, tournament_type=None, name='axelrod',
16+
def __init__(self, players, tournament_type=round_robin, name='axelrod',
1717
game=None, turns=200,
1818
repetitions=10, processes=None, prebuilt_cache=False,
1919
noise=0, with_morality=True, keep_matches=False):
@@ -45,10 +45,7 @@ def __init__(self, players, tournament_type=None, name='axelrod',
4545
Whether interaction results should be included in the output
4646
"""
4747
self.name = name
48-
if tournament_type is not None:
49-
self.tournament_type = tournament_type
50-
else:
51-
self.tournament_type = round_robin
48+
self.tournament_type = tournament_type
5249
self.turns = turns
5350
self.noise = noise
5451
if game is not None:

0 commit comments

Comments
 (0)