mirror of
https://github.com/ueberdosis/tiptap.git
synced 2024-11-25 12:39:03 +08:00
add test
This commit is contained in:
parent
ec61a37558
commit
703afe91c0
@ -153,7 +153,7 @@ context('/demos/Nodes/CodeBlock', () => {
|
||||
})
|
||||
})
|
||||
|
||||
it.only('removes the code block when pressing backspace, even with blank lines', () => {
|
||||
it.only('removes the code block when pressing backspace, even with blank lines', () => {
|
||||
cy.get('.ProseMirror').then(([{ editor }]) => {
|
||||
editor.commands.clearContent()
|
||||
|
||||
@ -167,4 +167,19 @@ context('/demos/Nodes/CodeBlock', () => {
|
||||
.should('not.exist')
|
||||
})
|
||||
})
|
||||
|
||||
it.only('removes the code block when pressing backspace, even at start of document', () => {
|
||||
cy.get('.ProseMirror').then(([{ editor }]) => {
|
||||
editor.commands.clearContent()
|
||||
|
||||
cy.get('.ProseMirror pre')
|
||||
.should('not.exist')
|
||||
|
||||
cy.get('.ProseMirror')
|
||||
.type('``` A{leftArrow}{backspace}')
|
||||
|
||||
cy.get('.ProseMirror pre')
|
||||
.should('not.exist')
|
||||
})
|
||||
})
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user