mirror of
https://github.com/scratchfoundation/scratch-blocks.git
synced 2025-07-29 07:10:04 -04:00
Remove test_maxBlocksWorkspace because limiting block numbers is not implemented in scratch-blocks
This commit is contained in:
parent
a206a46a21
commit
adb81f52dc
1 changed files with 0 additions and 21 deletions
|
@ -96,27 +96,6 @@ function test_flatWorkspace() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function test_maxBlocksWorkspace() {
|
|
||||||
workspaceTest_setUp();
|
|
||||||
try {
|
|
||||||
var blockA = workspace.newBlock('');
|
|
||||||
var blockB = workspace.newBlock('');
|
|
||||||
assertEquals('Infinite capacity.', Infinity, workspace.remainingCapacity());
|
|
||||||
workspace.options.maxBlocks = 3;
|
|
||||||
assertEquals('Three capacity.', 1, workspace.remainingCapacity());
|
|
||||||
workspace.options.maxBlocks = 2;
|
|
||||||
assertEquals('Two capacity.', 0, workspace.remainingCapacity());
|
|
||||||
workspace.options.maxBlocks = 1;
|
|
||||||
assertEquals('One capacity.', -1, workspace.remainingCapacity());
|
|
||||||
workspace.options.maxBlocks = 0;
|
|
||||||
assertEquals('Zero capacity.', -2, workspace.remainingCapacity());
|
|
||||||
workspace.clear();
|
|
||||||
assertEquals('Cleared capacity.', 0, workspace.remainingCapacity());
|
|
||||||
} finally {
|
|
||||||
workspaceTest_tearDown();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function test_getWorkspaceById() {
|
function test_getWorkspaceById() {
|
||||||
var workspaceA = new Blockly.Workspace();
|
var workspaceA = new Blockly.Workspace();
|
||||||
var workspaceB = new Blockly.Workspace();
|
var workspaceB = new Blockly.Workspace();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue