From 7d29a3f9bbc3cd403dec1f4540611ac009850761 Mon Sep 17 00:00:00 2001 From: Christopher Allen Date: Fri, 10 Jun 2022 16:06:47 +0100 Subject: [PATCH] refactor(tests): Remove special handling of msg/messages.js --- tests/bootstrap.js | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/tests/bootstrap.js b/tests/bootstrap.js index 4ccf7eb63..fe345d2cc 100644 --- a/tests/bootstrap.js +++ b/tests/bootstrap.js @@ -72,7 +72,6 @@ // List of scripts to load in compressed mode, instead of requires. compressedScripts: [ 'blockly_compressed.js', - 'msg/messages.js', 'blocks_compressed.js', 'dart_compressed.js', 'javascript_compressed.js', @@ -84,6 +83,7 @@ // Additional scripts to be loaded after Blockly is loaded, // whether Blockly is loaded from compressed or uncompressed. additionalScripts: [ + 'msg/messages.js', ], }; if (typeof window.BLOCKLY_BOOTSTRAP_OPTIONS === 'object') { @@ -117,19 +117,6 @@ document.write( ''); - // Msg loading kludge. This should go away once #5409 and/or - // #1895 are fixed. - - // Load messages into a temporary Blockly.Msg object, deleting it - // afterwards (after saving the messages!) - window.Blockly = {Msg: Object.create(null)}; - document.write( - ''); - document.write( - '\n'); const requiresString = options.requires.map(quote).join(); const scriptsString = options.additionalScripts.map(quote).join(); document.write( @@ -146,10 +133,6 @@ ' window.BlocklyLoader = new Promise((resolve, reject) => {\n' + ' goog.bootstrap(requires, resolve);\n' + ' }).then(() => {\n' + - ' // Copy Messages from temp Blockly.Msg object to the real one:\n' + - ' Object.assign(goog.module.get(\'Blockly\').Msg,\n' + - ' window.BlocklyMsg);\n' + - ' }).then(() => {\n' + ' return goog.module.get(\'Blockly\');\n' + ' });\n' + '\n');