From b03777f2df2064ec7fa6c10a9be034f7ddae73d5 Mon Sep 17 00:00:00 2001 From: Anne van Kesteren Date: Sun, 3 Sep 2023 14:33:32 +0200 Subject: [PATCH] HTML: search setter always uses UTF-8 We changed the Location search setter at some point to no longer pass the encoding argument, but it seems that for and the specification always required UTF-8. --- .../resolving-urls/query-encoding/resources/resolve-url.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/html/infrastructure/urls/resolving-urls/query-encoding/resources/resolve-url.js b/html/infrastructure/urls/resolving-urls/query-encoding/resources/resolve-url.js index 35088a037230b2..300a0a8dba1dc3 100644 --- a/html/infrastructure/urls/resolving-urls/query-encoding/resources/resolve-url.js +++ b/html/infrastructure/urls/resolving-urls/query-encoding/resources/resolve-url.js @@ -392,9 +392,9 @@ onload = function() { elm.href = input_arr[0]; elm.search = '?' + input_arr[1]; var got_href = elm.getAttribute('href'); - assert_true(got_href.indexOf(expected_current) > -1, 'href content attribute ' + msg(expected_current, got_href)); + assert_true(got_href.indexOf(expected_utf8) > -1, 'href content attribute ' + msg(expected_utf8, got_href)); var got_search = elm.search; - assert_true(got_search.indexOf(expected_current) > -1, 'getting .search '+msg(expected_current, got_search)); + assert_true(got_search.indexOf(expected_utf8) > -1, 'getting .search '+msg(expected_utf8, got_search)); }, '<'+tag+'>.search'); } 'a, area'.split(', ').forEach(function(str) {