mirror of
https://github.com/tusen-ai/naive-ui.git
synced 2024-11-27 04:09:51 +08:00
21 lines
510 B
JavaScript
21 lines
510 B
JavaScript
import './setupVue.js'
|
|
import fs from 'fs'
|
|
import path from 'path'
|
|
|
|
// eslint-disable-next-line n/no-exports-assign
|
|
exports = undefined
|
|
|
|
// eslint-disable-next-line no-eval
|
|
eval(
|
|
fs.readFileSync(path.resolve(__dirname, '..', 'dist', 'index.js')).toString()
|
|
)
|
|
|
|
describe('umd', () => {
|
|
it('works', () => {
|
|
const div = document.createElement('div')
|
|
document.body.appendChild(div)
|
|
window.Vue.createApp(window.naive.NDataTable).mount(div)
|
|
expect(div.innerHTML).toContain('n-data-table')
|
|
})
|
|
})
|