Add form magnet normalizer and tests

This commit is contained in:
thePR0M3TH3AN committed 2025-09-24 20:53:54 -04:00
1 parent 5795a7e7d4
commit 3b4bb7f0df
2 files changed
+171 -13

No files matched your search

+7
View File
@@ -135,6 +135,13 @@ function getParamValues(magnet, key) {
["https://cdn.example.com/video.torrent"],
"Expected xs hint to be appended"
);
const trackers = parsed.searchParams.getAll("tr");
for (const tracker of WSS_TRACKERS) {
assert.ok(
trackers.includes(tracker),
`Expected helper to append tracker ${tracker}`
);
}
})();
(function testFormHelperSkipsInsecureWsOnHttpsOrigin() {