Skip to content

Commit

Permalink
chore: unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
daithihearn committed Jan 17, 2024
1 parent 02dddf8 commit 321adfc
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions pkg/game/game_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,51 @@ func TestCall(t *testing.T) {
},
},
},
{
name: "Player calls JINK in 6 player game",
game: SixPlayerGame(),
calls: []CallWrap{
{
playerID: "5",
call: Jink,
expectedNextPlayerID: "1",
},
},
},
{
name: "Dealer takes JINK in 6 player game",
game: SixPlayerGame(),
calls: []CallWrap{
{
playerID: "5",
call: Jink,
expectedNextPlayerID: "1",
},
{
playerID: "1",
call: Jink,
expectedNextPlayerID: "1",
},
},
expectedGoerID: "1",
},
{
name: "Dealer lets JINK go in 6 player game",
game: SixPlayerGame(),
calls: []CallWrap{
{
playerID: "5",
call: Jink,
expectedNextPlayerID: "1",
},
{
playerID: "1",
call: Pass,
expectedNextPlayerID: "5",
},
},
expectedGoerID: "5",
},
}

for _, test := range tests {
Expand Down

0 comments on commit 321adfc

Please sign in to comment.