feat(test): add e2e tests for benchmarks and examples
Disables running the actual benchmarks on every commit as well to speed up the build.
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
var benchpress = require('../../../../tools/benchpress/index.js');
|
||||
describe('hello world', function () {
|
||||
|
||||
afterEach(benchpress.verifyNoBrowserErrors);
|
||||
|
||||
describe('static reflection', function() {
|
||||
var URL = 'examples/web/hello_world/index_static.html';
|
||||
|
||||
it('should greet', function() {
|
||||
browser.get(URL);
|
||||
|
||||
expect(getShadowText('hello-app')).toBe('hello world!');
|
||||
});
|
||||
});
|
||||
|
||||
describe('dynamic reflection', function() {
|
||||
var URL = 'examples/web/hello_world/index.html';
|
||||
|
||||
it('should greet', function() {
|
||||
browser.get(URL);
|
||||
|
||||
expect(getShadowText('hello-app')).toBe('hello world!');
|
||||
});
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
function getShadowText(selector) {
|
||||
return browser.executeScript('return document.querySelector("'+selector+'").shadowRoot.textContent');
|
||||
}
|
||||
Reference in New Issue
Block a user