mirror of
https://github.com/google/blockly.git
synced 2025-12-15 22:00:07 +01:00
fix: Fix toolbox categories tests (Almost)
This fixes the the toolbox categories tests except for dragging out the four empty statement blocks, which is fixed by https://github.com/google/blockly-samples/pull/2580 Once the latest version of samples is published the toolbox suite can be re-enabled.
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
import * as chai from 'chai';
|
||||
import {Key} from 'webdriverio';
|
||||
import {
|
||||
dragBlockTypeFromFlyout,
|
||||
getBlockTypeFromCategory,
|
||||
getCategory,
|
||||
PAUSE_TIME,
|
||||
screenDirection,
|
||||
@@ -148,7 +148,12 @@ async function openCategories(browser, categoryList, directionMultiplier) {
|
||||
continue;
|
||||
}
|
||||
const blockType = await getNthBlockType(browser, categoryName, i);
|
||||
dragBlockTypeFromFlyout(browser, categoryName, blockType, 50, 20);
|
||||
const blockElem = await getBlockTypeFromCategory(
|
||||
browser,
|
||||
categoryName,
|
||||
blockType,
|
||||
);
|
||||
await blockElem.dragAndDrop({x: 50 * directionMultiplier, y: 20});
|
||||
await browser.pause(PAUSE_TIME);
|
||||
// Should be one top level block on the workspace.
|
||||
const topBlockCount = await browser.execute(() => {
|
||||
|
||||
Reference in New Issue
Block a user