mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-21 18:55:19 -04:00
Add ability to use yaml-array for tags (#874)
This commit is contained in:
parent
bf42b9c460
commit
b2cf2f134e
8 changed files with 107 additions and 9 deletions
37
cypress/integration/metadata.spec.ts
Normal file
37
cypress/integration/metadata.spec.ts
Normal file
|
@ -0,0 +1,37 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2020 The HedgeDoc developers (see AUTHORS file)
|
||||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
describe('yaml-metadata: tags', () => {
|
||||
beforeEach(() => {
|
||||
cy.visit('/n/features')
|
||||
cy.get('.CodeMirror textarea')
|
||||
.type('{ctrl}a', { force: true })
|
||||
.type('{backspace}')
|
||||
})
|
||||
|
||||
it('show deprecation notice on old syntax', () => {
|
||||
cy.get('.CodeMirror textarea')
|
||||
.type('---\ntags: a, b, c\n---')
|
||||
cy.get('.splitter.right .w-100.h-100 .alert.alert-warning')
|
||||
.should('be.visible')
|
||||
})
|
||||
|
||||
it('show no deprecation notice on yaml-array (1)', () => {
|
||||
cy.get('.CodeMirror textarea')
|
||||
.type('---\ntags: [\'a\', \'b\', \'c\']\n---')
|
||||
cy.get('.splitter.right .w-100.h-100 .alert.alert-warning')
|
||||
.should('not.exist')
|
||||
})
|
||||
|
||||
it('show no deprecation notice on yaml-array (2)', () => {
|
||||
cy.get('.CodeMirror textarea')
|
||||
.type('---\ntags:\n - a\nb\nc\n')
|
||||
.type('{backspace}{backspace}{backspace}{backspace}')
|
||||
.type('---')
|
||||
cy.get('.splitter.right .w-100.h-100 .alert.alert-warning')
|
||||
.should('not.exist')
|
||||
})
|
||||
})
|
Loading…
Add table
Add a link
Reference in a new issue