2021-02-22 16:27:59 -05:00
|
|
|
/*
|
2022-06-08 07:19:51 -04:00
|
|
|
* SPDX-FileCopyrightText: 2022 The HedgeDoc developers (see AUTHORS file)
|
2021-02-22 16:27:59 -05:00
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
|
|
*/
|
|
|
|
|
|
|
|
describe('Link gets replaced with embedding: ', () => {
|
|
|
|
beforeEach(() => {
|
2022-01-30 15:46:43 -05:00
|
|
|
cy.visitTestNote()
|
2021-02-22 16:27:59 -05:00
|
|
|
})
|
|
|
|
|
2023-10-07 14:35:58 -04: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 16:27:59 -05:00
|
|
|
|
|
|
|
it('GitHub Gist', () => {
|
2021-10-04 06:50:39 -04:00
|
|
|
cy.setCodemirrorContent('https://gist.github.com/schacon/1')
|
2022-10-16 05:20:34 -04:00
|
|
|
cy.getMarkdownBody().findByCypressId('click-shield-gist').findByCypressId('preview-background').parent().click()
|
2021-12-25 10:44:24 -05:00
|
|
|
cy.getMarkdownBody().findByCypressId('gh-gist').should('be.visible')
|
2021-02-22 16:27:59 -05:00
|
|
|
})
|
|
|
|
})
|