summaryrefslogtreecommitdiffstats
path: root/tests/slots.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--tests/slots.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/slots.rs b/tests/slots.rs
index 12348c9..df4af28 100644
--- a/tests/slots.rs
+++ b/tests/slots.rs
@@ -48,6 +48,13 @@ fn no_match_returns_zero() {
48 assert_eq!(game.calculate_payout(&['G', 'D', 'S'], 50), 0); 48 assert_eq!(game.calculate_payout(&['G', 'D', 'S'], 50), 0);
49} 49}
50 50
51#[test]
52fn an_enormous_bet_saturates_instead_of_overflowing() {
53 let game = make_game();
54 assert_eq!(game.calculate_payout(&['S', 'S', 'S'], u64::MAX), u64::MAX);
55 assert_eq!(game.calculate_payout(&['S', 'L', 'S'], u64::MAX), u64::MAX);
56}
57
51/// process_action produces a finished state with correct reels and win_type. 58/// process_action produces a finished state with correct reels and win_type.
52#[test] 59#[test]
53fn process_action_spin_sets_finished() { 60fn process_action_spin_sets_finished() {