From cd6503d425d72a2174ca51eec35ae958075e17cb Mon Sep 17 00:00:00 2001 From: Angus McLeod Date: Wed, 28 Jun 2023 09:22:07 +0200 Subject: [PATCH] Remove fragile tests --- plugin.rb | 2 +- .../admin-wizards-unsuscribed-test.js | 32 ------------------- 2 files changed, 1 insertion(+), 33 deletions(-) diff --git a/plugin.rb b/plugin.rb index 5f166ca0..77b124fa 100644 --- a/plugin.rb +++ b/plugin.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # name: discourse-custom-wizard # about: Forms for Discourse. Better onboarding, structured posting, data enrichment, automated actions and much more. -# version: 2.4.7 +# version: 2.4.8 # authors: Angus McLeod, Faizaan Gagan, Robert Barrow, Keegan George, Kaitlin Maddever, Juan Marcos Gutierrez Ramos # url: https://github.com/paviliondev/discourse-custom-wizard # contact_emails: development@pavilion.tech diff --git a/test/javascripts/acceptance/admin-wizards-unsuscribed-test.js b/test/javascripts/acceptance/admin-wizards-unsuscribed-test.js index 3eb80dfd..bca7bc7c 100644 --- a/test/javascripts/acceptance/admin-wizards-unsuscribed-test.js +++ b/test/javascripts/acceptance/admin-wizards-unsuscribed-test.js @@ -441,38 +441,6 @@ acceptance("Admin | Custom Wizard Unsuscribed", function (needs) { assert.strictEqual(actualValue, "Some value", "Value is correct"); assert.strictEqual(actualResultText, "Result text", "Text is correct"); } - const fieldsContentSet = [ - [6, "bug", "1"], - [7, "gazelle", "gazelle"], - ]; - for (let [ - fieldIndex, - expectedDataName, - expectedDataValue, - ] of fieldsContentSet) { - await click( - `.admin-wizard-container .wizard-custom-action .setting:nth-of-type(${fieldIndex}) button` - ); - let selectKitInsideThirdSetting = await selectKit( - `.admin-wizard-container .wizard-custom-action .setting:nth-of-type(${fieldIndex}) .output .select-kit` - ); - await selectKitInsideThirdSetting.expand(); - await selectKitInsideThirdSetting.selectRowByIndex(1); - let selectKitElement = document.querySelector( - `.admin-wizard-container .wizard-custom-action .setting:nth-of-type(${fieldIndex}) .output .select-kit` - ); - let summaryElement = selectKitElement.querySelector("summary"); - assert.equal( - summaryElement.getAttribute("data-name"), - expectedDataName, - "The correct data-name is selected" - ); - assert.equal( - summaryElement.getAttribute("data-value"), - expectedDataValue, - "The correct data-value is selected" - ); - } assert.ok( !visible('.admin-wizard-buttons button:contains("Delete Wizard")'), "delete wizard button not displayed"