diff --git a/CHANGELOG.md b/CHANGELOG.md index f10c84e..7a599b3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -55,6 +55,8 @@ project follows [Semantic Versioning](https://semver.org/). ### Tests +- Added direct coverage for Android/touch card corner labels using Unicode suit + glyphs. - Added schema-v3 persistence round-trip coverage, foundation-to-tableau instruction coverage, expanded WASM unit tests, and Playwright E2E specs for browser routes and game-canvas behavior. diff --git a/SESSION_HANDOFF.md b/SESSION_HANDOFF.md index 83b0db3..29c606a 100644 --- a/SESSION_HANDOFF.md +++ b/SESSION_HANDOFF.md @@ -1,15 +1,15 @@ # Ferrous Solitaire — Session Handoff -**Last updated:** 2026-06-09 — analytics and Android validation runbooks added; handoff current. +**Last updated:** 2026-06-09 — validation runbooks added; card label coverage tightened. --- ## Current state -- **Branch state:** `master` pushed to origin; latest commits are validation runbooks plus handoff/changelog follow-up. +- **Branch state:** `master` pushed to origin; latest commits are validation runbooks plus card-label test coverage. - **Latest tag:** `v0.39.0` - **Working tree:** clean. Local `scripts/` helpers are excluded through `.git/info/exclude` and intentionally not committed. -- **Latest verification in this follow-up:** `cargo test -p solitaire_core`; `cargo test -p solitaire_data matomo_client`; `cargo test -p solitaire_engine analytics_plugin`; `cargo test -p solitaire_engine settings_plugin`. +- **Latest verification in this follow-up:** `cargo test -p solitaire_core`; `cargo test -p solitaire_data matomo_client`; `cargo test -p solitaire_engine analytics_plugin`; `cargo test -p solitaire_engine settings_plugin`; `cargo test -p solitaire_engine card_plugin`. - **Full previous gate:** Claude reported recent card_game work pushed to origin and `cargo test` / `clippy` gates passing before the changelog follow-up. --- diff --git a/solitaire_engine/src/card_plugin.rs b/solitaire_engine/src/card_plugin.rs index 440667d..ba96e4a 100644 --- a/solitaire_engine/src/card_plugin.rs +++ b/solitaire_engine/src/card_plugin.rs @@ -3024,7 +3024,7 @@ mod tests { } // ----------------------------------------------------------------------- - // label_for — remaining ranks not yet covered + // label_for / mobile_label_for // ----------------------------------------------------------------------- #[test] @@ -3081,6 +3081,26 @@ mod tests { } } + #[test] + fn mobile_label_for_uses_unicode_suit_glyphs() { + let cases = [ + (Suit::Clubs, Rank::Two, "2♣"), + (Suit::Diamonds, Rank::Ten, "10♦"), + (Suit::Hearts, Rank::Queen, "Q♥"), + (Suit::Spades, Rank::Ace, "A♠"), + ]; + + for (suit, rank, expected) in cases { + let card = Card { + id: 0, + suit, + rank, + face_up: true, + }; + assert_eq!(mobile_label_for(&card), expected); + } + } + #[test] fn facedown_cards_use_tighter_fan_than_uniform_faceup_fan() { let g = GameState::new(42, solitaire_core::game_state::DrawMode::DrawOne);