hedgedoc/cypress/integration/iframe-capsule.ts
Renovate Bot 77a60c6c48 Switch the base framework from Create React App to Next.JS
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-12-30 14:43:25 +01:00

17 lines
569 B
TypeScript

/*
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
describe('Iframe capsule', () => {
beforeEach(() => {
cy.visitTestEditor()
})
it('shows a clickable click shield instead of the iframe', () => {
cy.setCodemirrorContent('<iframe src="https://example.org"></iframe>')
cy.getMarkdownBody().findByCypressId('iframe-capsule-click-shield').should('exist').click()
cy.getMarkdownBody().find('iframe').should('exist').should('have.attr', 'src', 'https://example.org')
})
})