mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-27 10:20:42 +01:00
feat(Popover): new
This commit is contained in:
12
test/components/Popover.spec.ts
Normal file
12
test/components/Popover.spec.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { describe, it, expect } from 'vitest'
|
||||
import Popover, { type PopoverProps } from '../../src/runtime/components/Popover.vue'
|
||||
import ComponentRender from '../component-render'
|
||||
|
||||
describe('Popover', () => {
|
||||
it.each([
|
||||
['basic case', { props: { open: true, arrow: true }, slots: { default: () => 'Click me', content: () => 'Popover content' } }]
|
||||
])('renders %s correctly', async (nameOrHtml: string, options: { props?: PopoverProps, slots?: any }) => {
|
||||
const html = await ComponentRender(nameOrHtml, options, Popover)
|
||||
expect(html).toMatchSnapshot()
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user