2021-02-22 21:27:59 +00:00
|
|
|
/*
|
2022-06-08 11:19:51 +00:00
|
|
|
* SPDX-FileCopyrightText: 2022 The HedgeDoc developers (see AUTHORS file)
|
2021-02-22 21:27:59 +00:00
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
|
|
*/
|
|
|
|
|
|
|
|
describe('Link gets replaced with embedding: ', () => {
|
|
|
|
beforeEach(() => {
|
2022-01-30 20:46:43 +00:00
|
|
|
cy.visitTestNote()
|
2021-02-22 21:27:59 +00:00
|
|
|
})
|
|
|
|
|
2023-10-07 18:35:58 +00:00
|
|
|
// TODO Add general testing of one-click-embedding component.
|
|
|
|
// The tests below just test a specific use of the component.
|
|
|
|
// https://github.com/hedgedoc/hedgedoc/issues/5039
|
2021-02-22 21:27:59 +00:00
|
|
|
|
|
|
|
it('GitHub Gist', () => {
|
2021-10-04 10:50:39 +00:00
|
|
|
cy.setCodemirrorContent('https://gist.github.com/schacon/1')
|
2022-10-16 09:20:34 +00:00
|
|
|
cy.getMarkdownBody().findByCypressId('click-shield-gist').findByCypressId('preview-background').parent().click()
|
2021-12-25 15:44:24 +00:00
|
|
|
cy.getMarkdownBody().findByCypressId('gh-gist').should('be.visible')
|
2021-02-22 21:27:59 +00:00
|
|
|
})
|
|
|
|
})
|