Skip to content

Commit

Permalink
Add waits
Browse files Browse the repository at this point in the history
  • Loading branch information
michaeltaranto committed Mar 1, 2024
1 parent 2b79671 commit b7b0c39
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cypress/support/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,7 @@ export const assertCodePaneHasFocus = () => {
* @param {string} term
*/
export const findInCode = (term) => {
cy.wait(100); // eslint-disable-line @finsit/cypress/no-unnecessary-waiting
typeCode(`{${cmdPlus('f')}}`);
cy.get('.CodeMirror-search-field').type(`${term}{enter}`);
};
Expand All @@ -207,6 +208,7 @@ export const findInCode = (term) => {
*/

export const replaceInCode = (term, replaceWith) => {
cy.wait(100); // eslint-disable-line @finsit/cypress/no-unnecessary-waiting
typeCode(`{${cmdPlus('alt+f')}}`);
cy.get('.CodeMirror-search-field').type(`${term}{enter}`);
if (replaceWith) {
Expand All @@ -218,6 +220,7 @@ export const replaceInCode = (term, replaceWith) => {
* @param {number} line
*/
export const jumpToLine = (line) => {
cy.wait(100); // eslint-disable-line @finsit/cypress/no-unnecessary-waiting
typeCode(`{${cmdPlus('g')}}`);
cy.get('.CodeMirror-search-field').type(`${line}{enter}`);
};
Expand Down

0 comments on commit b7b0c39

Please sign in to comment.