normalize mocha spec duration in snapshot

This commit is contained in:
Gleb Bahmutov
2017-09-29 13:04:02 -04:00
parent 9e03942e58
commit 52e8598a96
2 changed files with 2 additions and 1 deletions

View File

@@ -18,7 +18,7 @@ exports['captures mocha output 1'] = `
✓ works
1 passing (10ms)
1 passing (<time>ms)
-------
stderr:
-------

View File

@@ -6,6 +6,7 @@ function normalize (s) {
// and the command is hardcoded in package.json
// using forward slashes
return s.replace(process.cwd(), '<folder path>')
.replace(/passing \(\d+ms\)/, 'passing (<time>ms)')
}
/* eslint-env mocha */