From 6f7297fee04ba862dce0397038cd64d612406f5d Mon Sep 17 00:00:00 2001 From: Christopher Allen Date: Thu, 27 Jul 2023 20:06:47 +0200 Subject: [PATCH] fix(tests): Make first basic block test agree with test plan The test plan specified to use a block from the Basic Blocks category of the test blocks. PR #7324 changed the test in a way that violated the plan, albeit in aid of a good cause: the basic blocks category had become unusable due to a bug in the test blocks combined with better error checking (in PR #7289). Since the test blocks were fixed by google/blockly-samples#1774 (and the fix published and Blockly updated by PR #7313) this violation can be corrected. --- tests/browser/test/basic_block_test.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tests/browser/test/basic_block_test.js b/tests/browser/test/basic_block_test.js index 7d594c50ede..baee5075ef0 100644 --- a/tests/browser/test/basic_block_test.js +++ b/tests/browser/test/basic_block_test.js @@ -14,7 +14,7 @@ const { testSetup, testFileLocations, getAllBlocks, - dragNthBlockFromFlyout, + dragBlockTypeFromFlyout, } = require('./test_setup'); const {Key} = require('webdriverio'); @@ -32,7 +32,13 @@ suite('Basic block tests', function (done) { test('Drag three blocks into the workspace', async function () { for (let i = 1; i <= 3; i++) { - await dragNthBlockFromFlyout(this.browser, 'Align', 0, 250, 50 * i); + await dragBlockTypeFromFlyout( + this.browser, + 'Basic', + 'test_basic_empty', + 250, + 50 * i + ); chai.assert.equal((await getAllBlocks(this.browser)).length, i); } });