Skip to content

Commit

Permalink
Fix firefox test.
Browse files Browse the repository at this point in the history
  • Loading branch information
sainthkh committed Sep 14, 2020
1 parent a831c7f commit a0b70ab
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/driver/cypress/integration/issues/7088_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,20 @@ describe('slatejs', () => {
const testString = 'Hello world'

cy.get('[data-slate-editor="true"]')
.type(testString, { })
.type(testString)

cy.contains('[data-slate-string="true"]', testString)
.should('be.visible')

cy.get('[data-slate-editor="true"]')
.type('{ctrl}{shift}{backspace}', { release: false })

// In Firefox, {ctrl}{shift}{backspace} deletes only one word.
if (Cypress.isBrowser('firefox')) {
cy.get('[data-slate-editor="true"]')
.type('{ctrl}{shift}{backspace}', { release: false })
}

cy.get('span[contenteditable="false"]').should('have.text', 'Enter some plain text...')
})
})

0 comments on commit a0b70ab

Please sign in to comment.