Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Fix iframe and widget test case for clicking #38039

Merged
merged 5 commits into from
Dec 9, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ describe(
propPane.UpdatePropertyFieldValue("URL", " ");
agHelper.ValidateToastMessage("url updated");

agHelper.ClickButton("Submit");
agHelper.ClickButton("Submit", { force: true });
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Avoid using force: true in button clicks

Using force: true bypasses Cypress's automatic retry and waiting mechanisms, which could mask underlying issues. Consider using Cypress's built-in waiting mechanisms instead.

-agHelper.ClickButton("Submit", { force: true });
+agHelper.WaitUntilEleAppear("Submit");
+agHelper.ClickButton("Submit");

Committable suggestion skipped: line range outside the PR's diff.

getIframeBody(0)
.find("input")
.should("be.visible")
Expand All @@ -90,6 +90,7 @@ describe(
expect(inputValue).to.equal("submitclicked");
});

EditorNavigation.SelectEntityByName("Iframe1", EntityType.Widget);
propPane.UpdatePropertyFieldValue(
"srcDoc",
`<!DOCTYPE html>
Expand Down
Loading