Last active
August 10, 2018 07:26
-
-
Save MonsieurMan/dedd2070af1247e7f561933c905b8c1d to your computer and use it in GitHub Desktop.
Unit testing Stencil component
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { TestWindow } from '@stencil/core/testing'; | |
import { Adder } from './adder'; | |
describe('adder', () => { | |
it('should build', () => { | |
expect(new Adder()).toBeTruthy(); | |
}); | |
describe('rendering', () => { | |
let element: HTMLAdderElement; | |
let testWindow: TestWindow; | |
beforeEach(async () => { | |
testWindow = new TestWindow(); | |
element = await testWindow.load({ | |
components: [Adder], | |
html: '<adder></adder>' | |
}); | |
}); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment