From 6d348e610db5dbc1aa17d1974295234e213d4422 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Tue, 27 Jan 2026 03:54:41 +0000 Subject: [PATCH] test: update VideoModal tag expectations to include hash prefix VideoModal now normalizes tags by prepending a `#` character if missing. This commit updates `tests/video-modal-controllers.test.mjs` to expect tags with the `#` prefix in assertions and the mock `TagPreferenceStateResolver`. Fixes: `VideoModal trims tag strip to fit modal width` assertion failure. Co-authored-by: PR0M3TH3AN <53631862+PR0M3TH3AN@users.noreply.github.com> --- tests/video-modal-controllers.test.mjs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/video-modal-controllers.test.mjs b/tests/video-modal-controllers.test.mjs index 297bfb86..4199e211 100644 --- a/tests/video-modal-controllers.test.mjs +++ b/tests/video-modal-controllers.test.mjs @@ -85,10 +85,10 @@ test("VideoModal trims tag strip to fit modal width", async (t) => { assert.ok(root, "tag container should be available after hydrate"); modal.setTagPreferenceStateResolver((tag) => { - if (tag === "alpha") { + if (tag === "#alpha") { return "interest"; } - if (tag === "beta") { + if (tag === "#beta") { return "disinterest"; } return "neutral"; @@ -143,7 +143,7 @@ test("VideoModal trims tag strip to fit modal width", async (t) => { assert.equal(trimmedButtons.length, 2, "tag list should be trimmed to fit"); assert.deepEqual( trimmedButtons.map((button) => button.dataset.tag), - ["alpha", "beta"], + ["#alpha", "#beta"], "leading tags should remain after trimming", ); assert.equal( @@ -185,7 +185,7 @@ test("VideoModal trims tag strip to fit modal width", async (t) => { ); assert.deepEqual( expandedButtons.map((button) => button.dataset.tag), - ["alpha", "beta", "delta"], + ["#alpha", "#beta", "#delta"], "reflow should restore full list order before trimming", ); });