nwb
Version:
A toolkit for React, Preact & Inferno apps, React libraries and other npm modules for the web, with no configuration (until you need it)
22 lines (16 loc) • 387 B
JavaScript
import expect from 'expect'
import {render} from 'inferno'
import App from 'src/App'
describe('App component', () => {
let node
beforeEach(() => {
node = document.createElement('div')
})
afterEach(() => {
render(null, node)
})
it('displays a welcome message', () => {
render(<App/>, node)
expect(node.textContent).toContain('Welcome to Inferno')
})
})