reduce typing delay and timeout

This commit is contained in:
Annie Huang committed 2023-12-04 16:45:25 +08:00
1 parent a911d953cd
commit 5b3c52bd9b
1 file changed
+2 -2
+2 -2
View File
@@ -39,7 +39,7 @@ Cypress.Commands.add('InitTerminal', () => {
}) })
Cypress.Commands.add('typeInCommand', (command) => { Cypress.Commands.add('typeInCommand', (command) => {
cy.get('.xterm-screen', { timeout: 150000 }).type(command, { cy.get('.xterm-screen', { timeout: 150000 }).type(command, {
delay: 100, delay: 50,
}) })
}) })
Cypress.Commands.add('getQuestInfo', (id) => { Cypress.Commands.add('getQuestInfo', (id) => {
@@ -109,7 +109,7 @@ Cypress.Commands.add('CompleteStageWithCommands', (stagename) => {
}) })
}) })
Cypress.Commands.add('CheckTextElement', (id, chText, enText) => { Cypress.Commands.add('CheckTextElement', (id, chText, enText) => {
cy.get(id, { timeout: 100000 }).within(($element) => { cy.get(id, { timeout: 10000 }).within(($element) => {
if (Cypress.env('isCHVersion')) { if (Cypress.env('isCHVersion')) {
cy.get($element).should('contain', chText).and('be.visible') cy.get($element).should('contain', chText).and('be.visible')
} else { } else {