fix readonly test

This commit is contained in:
Philipp Kühn
2021-03-15 14:29:32 +01:00
parent d0a15ad069
commit ee5283e13e

View File

@@ -3,10 +3,9 @@ context('/demos/Guide/Content/ReadOnly', () => {
cy.visit('/demos/Guide/Content/ReadOnly')
})
it.skip('should be read-only', () => {
it('should be read-only', () => {
cy.get('.ProseMirror').then(([{ editor }]) => {
cy.get('#editable').uncheck()
editor.setEditable(false)
editor.commands.insertText('Edited: ')
cy.get('.ProseMirror p:first').should('not.contain', 'Edited: ')
@@ -15,8 +14,7 @@ context('/demos/Guide/Content/ReadOnly', () => {
it('should be editable', () => {
cy.get('.ProseMirror').then(([{ editor }]) => {
cy.get('#editable').check()
editor.setEditable(true)
editor.commands.insertText('Edited: ')
cy.get('.ProseMirror p:first').should('contain', 'Edited: ')