mirror of
https://github.com/google/blockly.git
synced 2026-01-10 18:37:09 +01:00
fix(tests): Fix & reenable the advanced compilation test (#5781)
* fix(test): Fix advanced compilation test - Fix loading of blocks in `tests/compile/main.js` caused by recent `goog.module`-ification work. - Fix problem caused by ADVANCED_OPTIMISATIONS renaming the Msg property on the fake Blockly object created by the translation-loading hack in `blockly.js`. * chore(build): Reenable advanced compilation test Fixes #5602.
This commit is contained in:
committed by
GitHub
parent
b52c0179cb
commit
3d7262fed2
@@ -742,7 +742,7 @@ exports.zelos = zelos;
|
||||
// Blockly.Msg module - so make sure it is, but only if there is not
|
||||
// yet a Blockly global variable.
|
||||
if (!('Blockly' in globalThis)) {
|
||||
globalThis['Blockly'] = {Msg};
|
||||
globalThis['Blockly'] = {'Msg': Msg};
|
||||
}
|
||||
|
||||
// Temporary hack to copy accessor properties from exports to the
|
||||
|
||||
@@ -11,16 +11,8 @@ goog.require('Blockly');
|
||||
goog.require('Blockly.geras.Renderer');
|
||||
goog.require('Blockly.VerticalFlyout');
|
||||
// Blocks
|
||||
goog.require('Blockly.Constants.Logic');
|
||||
goog.require('Blockly.Constants.Loops');
|
||||
goog.require('Blockly.Constants.Math');
|
||||
goog.require('Blockly.Constants.TestBlocks');
|
||||
goog.require('Blockly.Constants.Text');
|
||||
goog.require('Blockly.Constants.Lists');
|
||||
goog.require('Blockly.Constants.Colour');
|
||||
goog.require('Blockly.Constants.Variables');
|
||||
goog.require('Blockly.Constants.VariablesDynamic');
|
||||
goog.require('Blockly.blocks.procedures');
|
||||
goog.require('Blockly.blocks.all');
|
||||
goog.require('Blockly.blocks.testBlocks');
|
||||
|
||||
Main.init = function() {
|
||||
Blockly.inject('blocklyDiv', {
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
*/
|
||||
'use strict';
|
||||
|
||||
goog.provide('Blockly.Constants.TestBlocks');
|
||||
goog.provide('Blockly.blocks.testBlocks');
|
||||
|
||||
goog.require('Blockly');
|
||||
|
||||
|
||||
@@ -76,8 +76,8 @@ run_test_command "package" "npm run package"
|
||||
# Run Node tests.
|
||||
run_test_command "node" "./node_modules/.bin/mocha tests/node --config tests/node/.mocharc.js"
|
||||
|
||||
# # Attempt advanced compilation of a Blockly app.
|
||||
# run_test_command "advanced_compile" "npm run test:compile:advanced"
|
||||
# Attempt advanced compilation of a Blockly app.
|
||||
run_test_command "advanced_compile" "npm run test:compile:advanced"
|
||||
|
||||
|
||||
# End of tests.
|
||||
|
||||
Reference in New Issue
Block a user