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: e2e failed #1671

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
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
4 changes: 2 additions & 2 deletions Composer/cypress/integration/Breadcrumb.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ context('breadcrumb', () => {
});

function hasBreadcrumbItems(cy: Cypress.cy, items: (string | RegExp)[]) {
cy.findByTestId('Breadcrumb')
cy.get('[data-testid="Breadcrumb"]')
.get('li')
.should($li => {
items.forEach((item, idx) => {
Expand All @@ -37,7 +37,7 @@ context('breadcrumb', () => {
cy.findByText('__TestTodoSample.Main').click();
});

hasBreadcrumbItems(cy, ['__TestTodoSample']);
hasBreadcrumbItems(cy, ['__TestTodoSample.Main']);
});

it('can show event name in breadcrumb', () => {
Expand Down
2 changes: 1 addition & 1 deletion Composer/cypress/integration/NotificationPage.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ context('Notification Page', () => {
beforeEach(() => {
cy.visit(Cypress.env('COMPOSER_URL'));
cy.createBot('TodoSample');
cy.visitPage('Notifications');
});

it('can show lg syntax error ', () => {
Expand All @@ -17,7 +18,6 @@ context('Notification Page', () => {
cy.get('textarea').type('test lg syntax error');

cy.visitPage('Notifications');

cy.get('[data-testid="notifications-table-view"]').within(() => {
cy.findByText('common.lg').should('exist');
});
Expand Down
5 changes: 5 additions & 0 deletions Composer/cypress/support/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,9 @@ Cypress.Commands.add('withinEditor', (editorName, cb) => {

Cypress.Commands.add('visitPage', page => {
cy.findByTestId(`LeftNav-CommandBarButton${page}`).click();
cy.wait(3000);
});

Cypress.on('uncaught:exception', (err, runnable) => {
return false;
});
2 changes: 1 addition & 1 deletion Composer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"test:coverage": "yarn test --coverage --no-cache --reporters=default",
"test:integration": "cypress run --browser chrome",
"test:integration:open": "cypress open",
"test:integration:clean": "rimraf TestBots/*",
"test:integration:clean": "rimraf ../MyBots/__Test*",
"lint": "wsrun --exclude-missing --collect-logs --report lint",
"lint:fix": "wsrun --exclude-missing --collect-logs --report lint:fix",
"typecheck": "concurrently --kill-others-on-fail \"npm:typecheck:*\"",
Expand Down
4 changes: 2 additions & 2 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ pr:
autoCancel: true
branches:
include:
- '*'
- "*"

variables:
YARN_CACHE_FOLDER: $(Pipeline.Workspace)/.yarn
Expand Down Expand Up @@ -52,7 +52,7 @@ jobs:
CYPRESS_SCREENSHOTS_FOLDER: $(Build.ArtifactStagingDirectory)/cypress/screenshots
CYPRESS_VIDEOS_FOLDER: $(Build.ArtifactStagingDirectory)/cypress/videos
TERM: xterm
COMPOSER_BOTS_FOLDER: $(Pipeline.Workspace)/Composer/TestBots
COMPOSER_BOTS_FOLDER: $(System.DefaultWorkingDirectory)/MyBots
- task: PublishPipelineArtifact@1
condition: failed()
continueOnError: true
Expand Down