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(editor): Don't open form popup window if different trigger node is used #13391

Merged
merged 1 commit into from
Feb 21, 2025

Conversation

autologie
Copy link
Contributor

Summary

When the workflow has multiple trigger nodes, clicking on "Test workflow" button on other trigger nodes should not open the form popup window.

Related Linear tickets, Github issues, and Community forum posts

https://linear.app/n8n/issue/SUG-16/bug-form-popup-shows-when-executing-a-different-trigger-via-popup

Review / Merge checklist

  • PR title and summary are descriptive. (conventions)
  • Docs updated or follow-up ticket created.
  • Tests included.
  • PR Labeled with release/backport (if the PR is an urgent fix that needs to be backported)

Comment on lines -14 to +10
vi.mock('./executionUtils', async () => {
const actual = await vi.importActual('./executionUtils');
return {
...actual,
openFormPopupWindow: vi.fn(),
};
});
const windowOpenSpy = vi.spyOn(window, 'open');
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Replacing the spy target, because it seemed that displayForm function always calls the actual implementation of openFormPopupWindow

@n8n-assistant n8n-assistant bot added n8n team Authored by the n8n team ui Enhancement in /editor-ui or /design-system labels Feb 20, 2025
Copy link

codecov bot commented Feb 20, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

📢 Thoughts on this report? Let us know!

@autologie autologie requested a review from mutdmour February 20, 2025 13:14
Copy link

cypress bot commented Feb 21, 2025

n8n    Run #9405

Run Properties:  status check passed Passed #9405  •  git commit 7861a8c7b1: 🌳 🖥️ browsers:node18.12.0-chrome107 🤖 autologie 🗃️ e2e/*
Project n8n
Branch Review sug-16-unwanted-form-popup-on-manual-execution
Run status status check passed Passed #9405
Run duration 04m 31s
Commit git commit 7861a8c7b1: 🌳 🖥️ browsers:node18.12.0-chrome107 🤖 autologie 🗃️ e2e/*
Committer autologie
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 5
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 437
View all changes introduced in this branch ↗︎

Copy link
Contributor

✅ All Cypress E2E specs passed

@autologie autologie merged commit 57a9a5b into master Feb 21, 2025
52 checks passed
@autologie autologie deleted the sug-16-unwanted-form-popup-on-manual-execution branch February 21, 2025 14:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
n8n team Authored by the n8n team ui Enhancement in /editor-ui or /design-system
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants