aboutsummaryrefslogtreecommitdiff
path: root/internal/casino/roulette_test.go
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-10-05 17:05:14 -0400
committerhistoria <[not public]>2026-10-05 17:05:14 -0400
commite42952469dadfb3535633c66c881050ac128703c (patch)
treea78f7396b72cdbd6fa4f6c454c830f40cf2ad0cb /internal/casino/roulette_test.go
parent90ad8c0c33b519d5830c69d4128bdc984b5e9de8 (diff)
downloadthehouseoficarus-e42952469dadfb3535633c66c881050ac128703c.tar.gz
fix: gather verbs, walk oom, admin path bypass, roulette refund
Diffstat (limited to 'internal/casino/roulette_test.go')
-rw-r--r--internal/casino/roulette_test.go8
1 files changed, 7 insertions, 1 deletions
diff --git a/internal/casino/roulette_test.go b/internal/casino/roulette_test.go
index 97bff2a..a0e04d4 100644
--- a/internal/casino/roulette_test.go
+++ b/internal/casino/roulette_test.go
@@ -356,7 +356,13 @@ func TestRouletteRefundAndPersistenceFailure(t *testing.T) {
table.markDisconnected("a")
table.refundAll()
table.tick()
- if w.chips != 100 || len(w.open) != 0 || w.paid != 0 {
+ if spinning {
+ // Once the spin starts the winning pocket is fixed; disconnecting
+ // forfeits the stake instead of allowing a selective refund.
+ if w.chips != 90 || len(w.open) != 0 || w.paid != 0 {
+ t.Fatalf("disconnect forfeit: %+v", w)
+ }
+ } else if w.chips != 100 || len(w.open) != 0 || w.paid != 0 {
t.Fatalf("disconnect refund: %+v", w)
}
}