Skip to content

Commit

Permalink
#8726 Try to fix hangs in Travis
Browse files Browse the repository at this point in the history
  • Loading branch information
asmecher committed Mar 3, 2023
1 parent d824412 commit 566c546
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 20 deletions.
10 changes: 1 addition & 9 deletions cypress/plugins/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,6 @@
let shouldSkip = false;
module.exports = ( on, config ) => {
on('task', {
resetShouldSkipFlag () {
shouldSkip = false;
return null;
},
shouldSkip ( value ) {
if ( value != null ) shouldSkip = value;
return shouldSkip;
},
failed: require('cypress-failed-log/src/failed')(),
consoleLog(message) {
console.log(message);
Expand All @@ -37,4 +29,4 @@ module.exports = ( on, config ) => {
}

return config;
}
}
10 changes: 0 additions & 10 deletions cypress/support/commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,16 +44,6 @@ Cypress.Commands.add('getTinyMceContent', (tinyMceId, content) => {
});
});

// See https://stackoverflow.com/questions/58657895/is-there-a-reliable-way-to-have-cypress-exit-as-soon-as-a-test-fails/58660504#58660504
Cypress.Commands.add('abortEarly', (self) => {
if (self.currentTest.state === 'failed') {
return cy.task('shouldSkip', true);
}
cy.task('shouldSkip').then(value => {
if (value) self.skip();
});
});

Cypress.Commands.add('runQueueJobs', (queue, test, once) => {
let command = 'php lib/pkp/tools/jobs.php run';

Expand Down
2 changes: 1 addition & 1 deletion lib/counterBots

0 comments on commit 566c546

Please sign in to comment.