From 928998dd2d417137944aac57e5ec2d03c258ace3 Mon Sep 17 00:00:00 2001 From: Filip Skokan Date: Sat, 25 Feb 2023 18:03:18 +0100 Subject: [PATCH] test: remove useless WPT init scripts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PR-URL: https://github.com/nodejs/node/pull/46801 Reviewed-By: Luigi Pinca Reviewed-By: James M Snell Reviewed-By: Michaƫl Zasso --- test/wpt/test-blob.js | 7 ------- test/wpt/test-broadcastchannel.js | 5 ----- test/wpt/test-encoding.js | 6 ------ 3 files changed, 18 deletions(-) diff --git a/test/wpt/test-blob.js b/test/wpt/test-blob.js index 0614c2d3fe36f1..0a0c16a4e3631b 100644 --- a/test/wpt/test-blob.js +++ b/test/wpt/test-blob.js @@ -5,11 +5,4 @@ const { WPTRunner } = require('../common/wpt'); const runner = new WPTRunner('FileAPI/blob'); -runner.setInitScript(` - const { Blob } = require('buffer'); - const { ReadableStream } = require('stream/web'); - global.Blob = Blob; - global.ReadableStream = ReadableStream; -`); - runner.runJsTests(); diff --git a/test/wpt/test-broadcastchannel.js b/test/wpt/test-broadcastchannel.js index 988a6270a936d6..d402d8be2f7c39 100644 --- a/test/wpt/test-broadcastchannel.js +++ b/test/wpt/test-broadcastchannel.js @@ -5,9 +5,4 @@ const { WPTRunner } = require('../common/wpt'); const runner = new WPTRunner('webmessaging/broadcastchannel'); -runner.setInitScript(` - const { BroadcastChannel } = require('worker_threads'); - global.BroadcastChannel = BroadcastChannel; -`); - runner.runJsTests(); diff --git a/test/wpt/test-encoding.js b/test/wpt/test-encoding.js index 901f53e00e22f0..bf54683c5c9f14 100644 --- a/test/wpt/test-encoding.js +++ b/test/wpt/test-encoding.js @@ -3,10 +3,4 @@ require('../common'); const { WPTRunner } = require('../common/wpt'); const runner = new WPTRunner('encoding'); -runner.setInitScript(` - globalThis.location ||= {}; - const { MessageChannel } = require('worker_threads'); - global.MessageChannel = MessageChannel; -`); - runner.runJsTests();