1919
2020def test_enumpure_strategy ():
2121 """Test calls of enumeration of pure strategies."""
22- game = games .read_from_file ("poker .efg" )
22+ game = games .read_from_file ("myerson_2_card_poker .efg" )
2323 assert len (gbt .nash .enumpure_solve (game , use_strategic = True ).equilibria ) == 0
2424
2525
2626def test_enumpure_agent ():
2727 """Test calls of enumeration of pure agent strategies."""
28- game = games .read_from_file ("poker .efg" )
28+ game = games .read_from_file ("myerson_2_card_poker .efg" )
2929 assert len (gbt .nash .enumpure_solve (game , use_strategic = False ).equilibria ) == 0
3030
3131
3232def test_enummixed_double ():
3333 """Test calls of enumeration of mixed strategy equilibria for 2-player games, floating-point.
3434 """
35- game = games .read_from_file ("poker .efg" )
35+ game = games .read_from_file ("myerson_2_card_poker .efg" )
3636 result = gbt .nash .enummixed_solve (game , rational = False )
3737 assert len (result .equilibria ) == 1
3838 # For floating-point results are not exact, so we skip testing exact values for now
@@ -44,7 +44,6 @@ def test_enummixed_double():
4444 "game,mixed_strategy_prof_data" ,
4545 [
4646 # Zero-sum games
47- (games .create_1_card_poker_efg (), [[["1/3" , "2/3" , 0 , 0 ], ["2/3" , "1/3" ]]]),
4847 (games .create_myerson_2_card_poker_efg (), [[["1/3" , "2/3" , 0 , 0 ], ["2/3" , "1/3" ]]]),
4948 # Non-zero-sum games
5049 (games .create_one_shot_trust_efg (), [[[0 , 1 ], ["1/2" , "1/2" ]],
@@ -90,11 +89,6 @@ def test_enummixed_rational(game: gbt.Game, mixed_strategy_prof_data: list):
9089 "game,mixed_behav_prof_data,stop_after" ,
9190 [
9291 # 2-player zero-sum games
93- (
94- games .create_1_card_poker_efg (),
95- [[[[1 , 0 ], ["1/3" , "2/3" ]], [["2/3" , "1/3" ]]]],
96- None ,
97- ),
9892 (
9993 games .create_myerson_2_card_poker_efg (),
10094 [[[[1 , 0 ], ["1/3" , "2/3" ]], [["2/3" , "1/3" ]]]],
@@ -240,7 +234,7 @@ def are_the_same(game, found, candidate):
240234
241235def test_lcp_strategy_double ():
242236 """Test calls of LCP for mixed strategy equilibria, floating-point."""
243- game = games .read_from_file ("poker .efg" )
237+ game = games .read_from_file ("myerson_2_card_poker .efg" )
244238 result = gbt .nash .lcp_solve (game , use_strategic = True , rational = False )
245239 assert len (result .equilibria ) == 1
246240 # For floating-point results are not exact, so we skip testing exact values for now
@@ -252,7 +246,6 @@ def test_lcp_strategy_double():
252246 "game,mixed_strategy_prof_data,stop_after" ,
253247 [
254248 # Zero-sum games
255- (games .create_1_card_poker_efg (), [[["1/3" , "2/3" , 0 , 0 ], ["2/3" , "1/3" ]]], None ),
256249 (games .create_myerson_2_card_poker_efg (), [[["1/3" , "2/3" , 0 , 0 ], ["2/3" , "1/3" ]]], None ),
257250 (games .create_kuhn_poker_efg (), [games .kuhn_poker_lcp_first_mixed_strategy_prof ()], 1 ),
258251 # Non-zero-sum games
@@ -311,7 +304,7 @@ def test_lcp_strategy_rational(game: gbt.Game, mixed_strategy_prof_data: list,
311304
312305def test_lcp_behavior_double ():
313306 """Test calls of LCP for mixed behavior equilibria, floating-point."""
314- game = games .read_from_file ("poker .efg" )
307+ game = games .read_from_file ("myerson_2_card_poker .efg" )
315308 result = gbt .nash .lcp_solve (game , use_strategic = False , rational = False )
316309 assert len (result .equilibria ) == 1
317310 # For floating-point results are not exact, so we skip testing exact values for now
@@ -323,7 +316,6 @@ def test_lcp_behavior_double():
323316 "game,mixed_behav_prof_data" ,
324317 [
325318 # Zero-sum games (also tested with lp solve)
326- (games .create_1_card_poker_efg (), [[[1 , 0 ], ["1/3" , "2/3" ]], [["2/3" , "1/3" ]]]),
327319 (games .create_myerson_2_card_poker_efg (), [[[1 , 0 ], ["1/3" , "2/3" ]], [["2/3" , "1/3" ]]]),
328320 (
329321 games .create_kuhn_poker_efg (),
@@ -380,7 +372,7 @@ def test_lcp_behavior_rational(game: gbt.Game, mixed_behav_prof_data: list):
380372
381373def test_lp_strategy_double ():
382374 """Test calls of LP for mixed strategy equilibria, floating-point."""
383- game = games .read_from_file ("poker .efg" )
375+ game = games .read_from_file ("myerson_2_card_poker .efg" )
384376 result = gbt .nash .lp_solve (game , use_strategic = True , rational = False )
385377 assert len (result .equilibria ) == 1
386378 # For floating-point results are not exact, so we skip testing exact values for now
@@ -390,7 +382,7 @@ def test_lp_strategy_double():
390382@pytest .mark .nash_lp_strategy
391383def test_lp_strategy_rational ():
392384 """Test calls of LP for mixed strategy equilibria, rational precision."""
393- game = games .read_from_file ("poker .efg" )
385+ game = games .read_from_file ("myerson_2_card_poker .efg" )
394386 result = gbt .nash .lp_solve (game , use_strategic = True , rational = True )
395387 assert len (result .equilibria ) == 1
396388 expected = game .mixed_strategy_profile (
@@ -405,7 +397,7 @@ def test_lp_strategy_rational():
405397
406398def test_lp_behavior_double ():
407399 """Test calls of LP for mixed behavior equilibria, floating-point."""
408- game = games .read_from_file ("poker .efg" )
400+ game = games .read_from_file ("myerson_2_card_poker .efg" )
409401 result = gbt .nash .lp_solve (game , use_strategic = False , rational = False )
410402 assert len (result .equilibria ) == 1
411403 # For floating-point results are not exact, so we skip testing exact values for now
@@ -420,7 +412,6 @@ def test_lp_behavior_double():
420412 games .create_two_player_perfect_info_win_lose_efg (),
421413 [[[0 , 1 ], [1 , 0 ]], [[1 , 0 ], [1 , 0 ]]],
422414 ),
423- (games .create_1_card_poker_efg (), [[[1 , 0 ], ["1/3" , "2/3" ]], [["2/3" , "1/3" ]]]),
424415 (
425416 games .create_myerson_2_card_poker_efg (),
426417 [[[1 , 0 ], ["1/3" , "2/3" ]], [["2/3" , "1/3" ]]],
@@ -456,47 +447,47 @@ def test_lp_behavior_rational(game: gbt.Game, mixed_behav_prof_data: list):
456447
457448def test_liap_strategy ():
458449 """Test calls of liap for mixed strategy equilibria."""
459- game = games .read_from_file ("poker .efg" )
450+ game = games .read_from_file ("myerson_2_card_poker .efg" )
460451 _ = gbt .nash .liap_solve (game .mixed_strategy_profile ())
461452
462453
463454def test_liap_behavior ():
464455 """Test calls of liap for mixed behavior equilibria."""
465- game = games .read_from_file ("poker .efg" )
456+ game = games .read_from_file ("myerson_2_card_poker .efg" )
466457 _ = gbt .nash .liap_solve (game .mixed_behavior_profile ())
467458
468459
469460def test_simpdiv_strategy ():
470461 """Test calls of simplicial subdivision for mixed strategy equilibria."""
471- game = games .read_from_file ("poker .efg" )
462+ game = games .read_from_file ("myerson_2_card_poker .efg" )
472463 result = gbt .nash .simpdiv_solve (game .mixed_strategy_profile (rational = True ))
473464 assert len (result .equilibria ) == 1
474465
475466
476467def test_ipa_strategy ():
477468 """Test calls of IPA for mixed strategy equilibria."""
478- game = games .read_from_file ("poker .efg" )
469+ game = games .read_from_file ("myerson_2_card_poker .efg" )
479470 result = gbt .nash .ipa_solve (game )
480471 assert len (result .equilibria ) == 1
481472
482473
483474def test_gnm_strategy ():
484475 """Test calls of GNM for mixed strategy equilibria."""
485- game = games .read_from_file ("poker .efg" )
476+ game = games .read_from_file ("myerson_2_card_poker .efg" )
486477 result = gbt .nash .gnm_solve (game )
487478 assert len (result .equilibria ) == 1
488479
489480
490481def test_logit_strategy ():
491482 """Test calls of logit for mixed strategy equilibria."""
492- game = games .read_from_file ("poker .efg" )
483+ game = games .read_from_file ("myerson_2_card_poker .efg" )
493484 result = gbt .nash .logit_solve (game , use_strategic = True )
494485 assert len (result .equilibria ) == 1
495486
496487
497488def test_logit_behavior ():
498489 """Test calls of logit for behavior equilibria."""
499- game = games .read_from_file ("poker .efg" )
490+ game = games .read_from_file ("myerson_2_card_poker .efg" )
500491 result = gbt .nash .logit_solve (game , use_strategic = False )
501492 assert len (result .equilibria ) == 1
502493
0 commit comments