Skip to content

Commit

Permalink
Add test print_board_when_game_undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
DOBRO committed Mar 22, 2022
1 parent e02fcb7 commit 0917a5d
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions test/play_game_SUITE.erl
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@
set_game_state/1,
get_pieces_list/1,
index_moves/1,
set_game_winner/1
set_game_winner/1,
print_board_when_game_undefined/1
]).


Expand All @@ -61,7 +62,8 @@ groups() ->
get_pieces_list,
index_moves,
set_game_winner,
rule50
rule50,
print_board_when_game_undefined
]}].

%% init_per_suite/1
Expand Down Expand Up @@ -515,6 +517,7 @@ index_moves(Config) ->

ok.

%% set_game_winner/1
set_game_winner(Config) ->
Pid = get_pid(Config),
% winner1
Expand Down Expand Up @@ -551,6 +554,13 @@ set_game_winner(Config) ->

ok.

%% print_board_when_game_undefined
print_board_when_game_undefined(Config) ->
Pid = get_pid(Config),
{error,{bad_game,undefined}} = binbo:print_board(Pid),
ok.


%%%------------------------------------------------------------------------------
%%% Internal helpers
%%%------------------------------------------------------------------------------
Expand Down

0 comments on commit 0917a5d

Please sign in to comment.