mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-16 09:36:44 +00:00
feat(editor): Add follow up question nps (#17459)
This commit is contained in:
@@ -3,8 +3,9 @@ import { clearNotifications } from '../pages/notifications';
|
||||
import {
|
||||
getNpsSurvey,
|
||||
getNpsSurveyClose,
|
||||
getNpsSurveyEmail,
|
||||
getNpsSurveyFeedback,
|
||||
getNpsSurveyRatings,
|
||||
getNpsSurveySubmit,
|
||||
} from '../pages/npsSurvey';
|
||||
import { WorkflowPage } from '../pages/workflow';
|
||||
|
||||
@@ -22,7 +23,7 @@ describe('NpsSurvey', () => {
|
||||
cy.signin(INSTANCE_ADMIN);
|
||||
});
|
||||
|
||||
it('shows nps survey to recently activated user and can submit email ', () => {
|
||||
it('shows nps survey to recently activated user and can submit feedback ', () => {
|
||||
cy.intercept('/rest/settings', { middleware: true }, (req) => {
|
||||
req.on('response', (res) => {
|
||||
if (res.body.data) {
|
||||
@@ -56,8 +57,8 @@ describe('NpsSurvey', () => {
|
||||
getNpsSurveyRatings().find('button').should('have.length', 11);
|
||||
getNpsSurveyRatings().find('button').first().click();
|
||||
|
||||
getNpsSurveyEmail().find('input').type('test@n8n.io');
|
||||
getNpsSurveyEmail().find('button').click();
|
||||
getNpsSurveyFeedback().find('textarea').type('n8n is the best');
|
||||
getNpsSurveySubmit().find('button').click();
|
||||
|
||||
// test that modal does not show up again until 6 months later
|
||||
workflowPage.actions.visit(true, NOW + ONE_DAY);
|
||||
|
||||
@@ -6,7 +6,8 @@ export const getNpsSurvey = () => cy.getByTestId('nps-survey-modal');
|
||||
|
||||
export const getNpsSurveyRatings = () => cy.getByTestId('nps-survey-ratings');
|
||||
|
||||
export const getNpsSurveyEmail = () => cy.getByTestId('nps-survey-email');
|
||||
export const getNpsSurveyFeedback = () => cy.getByTestId('nps-survey-feedback');
|
||||
export const getNpsSurveySubmit = () => cy.getByTestId('nps-survey-feedback-button');
|
||||
|
||||
export const getNpsSurveyClose = () =>
|
||||
cy.getByTestId('nps-survey-modal').find('button.el-drawer__close-btn');
|
||||
|
||||
Reference in New Issue
Block a user