Skip to content

Commit

Permalink
fix(cli): add endTimer() for page load timer (#236)
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-siek committed Apr 28, 2021
1 parent 18d5848 commit e0a19a3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions packages/cli/src/bin/cli.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,7 @@ describe('cli', () => {
it('should log the time it takes to run', async () => {
const result = await runCLI(`file://${SIMPLE_HTML_FILE}`, '--timer');
assert.equal(result.exitCode, 0);
assert.isEmpty(result.stderr);
assert.include(result.stdout, 'axe-core execution time');
assert.include(result.stdout, 'Total test time');
});
Expand Down
4 changes: 2 additions & 2 deletions packages/cli/src/lib/axe-test-urls.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const testPages = async (
}

if (config.timer) {
events?.startTimer('page load time');
events?.startTimer('axe page load time');
}

driver
Expand All @@ -46,7 +46,7 @@ const testPages = async (
})
.then(() => {
if (config.timer) {
events?.startTimer('page load time');
events?.endTimer('axe page load time');
}

if (config.loadDelay) {
Expand Down

0 comments on commit e0a19a3

Please sign in to comment.