From ba2697b7039206ba0040aedb16e37ee66bb54552 Mon Sep 17 00:00:00 2001 From: Ioodu Date: Mon, 13 Apr 2026 10:25:09 +0800 Subject: [PATCH 1/2] fix: cover quick steady and cozy catalog states Add regression tests and multilingual catalog rows for policy-reachable quick steady/cozy moods so render no longer falls back for those cases. Co-Authored-By: Claude Opus 4.6 --- scripts/messages/catalog_en.tsv | 2 ++ scripts/messages/catalog_es.tsv | 2 ++ scripts/messages/catalog_ja.tsv | 2 ++ scripts/messages/catalog_ko.tsv | 2 ++ scripts/messages/catalog_zh.tsv | 2 ++ tests/render_test.sh | 34 +++++++++++++++++++++++++++++++++ 6 files changed, 44 insertions(+) diff --git a/scripts/messages/catalog_en.tsv b/scripts/messages/catalog_en.tsv index 8b4c4b9..e384b22 100644 --- a/scripts/messages/catalog_en.tsv +++ b/scripts/messages/catalog_en.tsv @@ -11,6 +11,8 @@ big|triumphant|en_big_triumphant_1|Big finish. You pushed it through beautifully big|streak|en_big_streak_1|That is another strong hit in the streak. Keep going. big|hype|en_big_hype_1|Huge energy. You just turned effort into momentum. legendary|milestone|en_legendary_milestone_1|Milestone unlocked. This session has main-character energy. +quick|steady|en_quick_steady_1|Consistent pace. One more in the books. +quick|cozy|en_quick_cozy_1|Quiet and warm and done. That is the way. quick|gentle|en_quick_gentle_2|Small step, real progress. Keep it rolling. quick|gentle|en_quick_gentle_3|One more down. Smooth and steady. quick|hype|en_quick_hype_2|Quick and clean. That is how it is done. diff --git a/scripts/messages/catalog_es.tsv b/scripts/messages/catalog_es.tsv index 6c346c8..890f2ca 100644 --- a/scripts/messages/catalog_es.tsv +++ b/scripts/messages/catalog_es.tsv @@ -21,6 +21,8 @@ big|hype|es_big_hype_1|Rendimiento máximo. Acabas de subir de nivel. big|hype|es_big_hype_2|Energía brutal. Convirtiendo esfuerzo en momento. legendary|milestone|es_legendary_milestone_1|Logro desbloqueado. Los números no mienten. legendary|milestone|es_legendary_milestone_2|Acabas de hacer historia. Sesión legendaria. +quick|steady|es_quick_steady_1|Ritmo constante. Uno más en el registro. +quick|cozy|es_quick_cozy_1|Tranquilo y listo. Así de sencillo. quick|gentle|es_quick_gentle_3|Uno más completado. El ritmo no se detiene. solid|steady|es_solid_steady_4|Cierre impecable. Trabajo de primera. solid|rapid_fire|es_solid_rapid_fire_3|Victorias seguidas. El ritmo es imparable. diff --git a/scripts/messages/catalog_ja.tsv b/scripts/messages/catalog_ja.tsv index b900e5a..5197151 100644 --- a/scripts/messages/catalog_ja.tsv +++ b/scripts/messages/catalog_ja.tsv @@ -11,6 +11,8 @@ big|triumphant|ja_big_triumphant_1|大きな完了です。見事に押し切り big|streak|ja_big_streak_1|連続の好調です。この勢いを大事にしましょう。 big|hype|ja_big_hype_1|熱いですね。今の一手で流れを作りました。 legendary|milestone|ja_legendary_milestone_1|マイルストーン達成です。今日は主役級の流れです。 +quick|steady|ja_quick_steady_1|着実なペースです。また一つ積み上げました。 +quick|cozy|ja_quick_cozy_1|ほっこり完了。静かにでも確実に前進。 quick|gentle|ja_quick_gentle_2|小さな一歩、確かな前進です。 quick|gentle|ja_quick_gentle_3|また一つ完了。滑らかですね。 quick|hype|ja_quick_hype_2|速攻クリーン。これこそプロの仕事。 diff --git a/scripts/messages/catalog_ko.tsv b/scripts/messages/catalog_ko.tsv index 280da3a..416e558 100644 --- a/scripts/messages/catalog_ko.tsv +++ b/scripts/messages/catalog_ko.tsv @@ -21,6 +21,8 @@ big|hype|ko_big_hype_1|피크 퍼포먼스! 레벨업하셨어요. big|hype|ko_big_hype_2|이건 전설적인 한 수! 모멘텀이 살아있어요. legendary|milestone|ko_legendary_milestone_1|업적 달성! 숫자는 거짓말하지 않아요. legendary|milestone|ko_legendary_milestone_2|역사를 만드셨어요. 전설적인 세션입니다. +quick|steady|ko_quick_steady_1|꾸준한 페이스네요. 또 하나 쌓였어요. +quick|cozy|ko_quick_cozy_1|포근하게 완료. 조용하지만 확실해요. quick|gentle|ko_quick_gentle_3|또 하나 해냈네요. 흐름이 끊기지 않아요. solid|steady|ko_solid_steady_4|끝내주는 마무리. 깔끔 그 자체예요. solid|rapid_fire|ko_solid_rapid_fire_3|연달아 클리어! 템포가 끝내줘요. diff --git a/scripts/messages/catalog_zh.tsv b/scripts/messages/catalog_zh.tsv index 36bf70c..75c7bfb 100644 --- a/scripts/messages/catalog_zh.tsv +++ b/scripts/messages/catalog_zh.tsv @@ -11,6 +11,8 @@ big|triumphant|zh_big_triumphant_1|漂亮的大收尾,这次推进很有分量 big|streak|zh_big_streak_1|连胜继续,你今天的推进感非常强。 big|hype|zh_big_hype_1|这一下太提气了,直接把 momentum 打出来了。 legendary|milestone|zh_legendary_milestone_1|里程碑达成,今天这波真的有主角气场。 +quick|steady|zh_quick_steady_1|节奏稳稳的,又一个拿下了。 +quick|cozy|zh_quick_cozy_1|轻松收工,舒适又自在。 quick|gentle|zh_quick_gentle_2|小步快跑,进步看得见。 quick|gentle|zh_quick_gentle_3|又稳了一步,节奏保持住。 quick|hype|zh_quick_hype_2|干净利落,这一波操作很秀。 diff --git a/tests/render_test.sh b/tests/render_test.sh index 5cdd605..1d29449 100644 --- a/tests/render_test.sh +++ b/tests/render_test.sh @@ -108,6 +108,38 @@ test_render_quick_hype_picks_catalog_row() { assert_contains "$RENDER_MESSAGE_TEXT" "spark alive" } +test_render_quick_steady_picks_catalog_row() { + CHEERER_ROOT="$PWD" + CHEERER_LANG="en" + POLICY_TIER="quick" + POLICY_MOOD="steady" + RECENT_MESSAGE_IDS="" + STATE_MILESTONE_MSG="" + CHEERER_CUSTOM_ONLY="false" + CHEERER_CUSTOM_MSG="" + + render_select_message + + assert_eq "en_quick_steady_1" "$RENDER_MESSAGE_ID" + assert_contains "$RENDER_MESSAGE_TEXT" "Consistent pace" +} + +test_render_quick_cozy_picks_catalog_row() { + CHEERER_ROOT="$PWD" + CHEERER_LANG="en" + POLICY_TIER="quick" + POLICY_MOOD="cozy" + RECENT_MESSAGE_IDS="" + STATE_MILESTONE_MSG="" + CHEERER_CUSTOM_ONLY="false" + CHEERER_CUSTOM_MSG="" + + render_select_message + + assert_eq "en_quick_cozy_1" "$RENDER_MESSAGE_ID" + assert_contains "$RENDER_MESSAGE_TEXT" "warm and done" +} + test_render_solid_streak_picks_catalog_row() { CHEERER_ROOT="$PWD" CHEERER_LANG="en" @@ -214,6 +246,8 @@ run_test "soft_intensity_skips_quick_animation" test_soft_intensity_skips_quick_ run_test "epic_mode_animates_all_three" test_epic_mode_animates_all_three run_test "render_solid_rapid_fire_picks_catalog_row" test_render_solid_rapid_fire_picks_catalog_row run_test "render_quick_hype_picks_catalog_row" test_render_quick_hype_picks_catalog_row +run_test "render_quick_steady_picks_catalog_row" test_render_quick_steady_picks_catalog_row +run_test "render_quick_cozy_picks_catalog_row" test_render_quick_cozy_picks_catalog_row run_test "render_solid_streak_picks_catalog_row" test_render_solid_streak_picks_catalog_row run_test "render_solid_triumphant_picks_catalog_row" test_render_solid_triumphant_picks_catalog_row run_test "render_custom_only_uses_custom_file" test_render_custom_only_uses_custom_file From 8dd70d1b1e52a6e3e9c6ddb189f17994a228ea69 Mon Sep 17 00:00:00 2001 From: Ioodu Date: Mon, 13 Apr 2026 10:36:08 +0800 Subject: [PATCH 2/2] test: stabilize quick cozy assertion Use the stable leading phrase in the quick cozy render test so catalog wording changes do not break the regression for the wrong reason. Co-Authored-By: Claude Opus 4.6 --- tests/render_test.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/render_test.sh b/tests/render_test.sh index 1d29449..fd68a94 100644 --- a/tests/render_test.sh +++ b/tests/render_test.sh @@ -137,7 +137,7 @@ test_render_quick_cozy_picks_catalog_row() { render_select_message assert_eq "en_quick_cozy_1" "$RENDER_MESSAGE_ID" - assert_contains "$RENDER_MESSAGE_TEXT" "warm and done" + assert_contains "$RENDER_MESSAGE_TEXT" "Quiet and warm" } test_render_solid_streak_picks_catalog_row() {