mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
tests ok, lint ok
This commit is contained in:
parent
fd697f5f12
commit
574fbcf8b1
@ -161,7 +161,7 @@ export default class Embed extends Node {
|
||||
},
|
||||
removeEmbed() {
|
||||
// TODO: replace the whole Embed with a proper Link node
|
||||
console.log('I want to be a Link!')
|
||||
// console.log('I want to be a Link!')
|
||||
this.removeEmbeds = true
|
||||
},
|
||||
async updateEmbedSettings(allowEmbedIframes) {
|
||||
|
||||
@ -14,11 +14,11 @@ describe('Embed.vue', () => {
|
||||
}
|
||||
})
|
||||
|
||||
it('renders anchor', () => {
|
||||
it('renders ds-container', () => {
|
||||
propsData = {
|
||||
node: { attrs: { href: someUrl } },
|
||||
}
|
||||
expect(Wrapper({ propsData }).is('a')).toBe(true)
|
||||
expect(Wrapper({ propsData }).is('ds-container')).toBe(true)
|
||||
})
|
||||
|
||||
describe('given a href', () => {
|
||||
@ -49,8 +49,8 @@ describe('Embed.vue', () => {
|
||||
propsData.node = { attrs: { href: 'https://www.youtube.com/watch?v=qkdXAtO40Fo' } }
|
||||
const wrapper = Wrapper({ propsData })
|
||||
await wrapper.html()
|
||||
expect(wrapper.find('div iframe').attributes('src')).toEqual(
|
||||
'https://www.youtube.com/embed/qkdXAtO40Fo?feature=oembed',
|
||||
expect(wrapper.find('ds-container img').attributes('src')).toEqual(
|
||||
'https://i.ytimg.com/vi/qkdXAtO40Fo/maxresdefault.jpg',
|
||||
)
|
||||
})
|
||||
})
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user