fix(benchmarks): wait for end of benchmarks

This commit is contained in:
Tobias Bosch 2015-04-21 10:11:59 -07:00
parent 14a7b9f794
commit 97e6fb6835
2 changed files with 5 additions and 5 deletions

View File

@ -33,7 +33,7 @@ function runBenchmark(config) {
}
var url = encodeURI(config.url + '?' + urlParams.join('&'));
return browser.get(url).then(function() {
benchpressRunner.sample({
return benchpressRunner.sample({
id: config.id,
execute: config.work,
prepare: config.prepare,

View File

@ -18,7 +18,7 @@ describe('ng2 largetable benchmark', function () {
'interpolationAttr',
'interpolationFn'
].forEach(function(benchmarkType) {
it('should log the ng stats with: ' + benchmarkType, function() {
it('should log the ng stats with: ' + benchmarkType, function(done) {
console.log('executing for type', benchmarkType);
perfUtil.runClickBenchmark({
url: URL,
@ -36,12 +36,12 @@ describe('ng2 largetable benchmark', function () {
name: 'benchmarkType',
value: benchmarkType
}]
});
}).then(done, done.fail);
});
});
it('should log the baseline stats', function() {
it('should log the baseline stats', function(done) {
perfUtil.runClickBenchmark({
url: URL,
buttons: ['#baselineDestroyDom', '#baselineCreateDom'],
@ -58,7 +58,7 @@ describe('ng2 largetable benchmark', function () {
name: 'benchmarkType',
value: 'baseline'
}]
});
}).then(done, done.fail);;
});
});