Skip to content

Commit

Permalink
Add warning to test.html that there is a regexp parsing the text outp…
Browse files Browse the repository at this point in the history
…ut, and made that regexp slightly more resilient.
  • Loading branch information
hildjj committed Jul 28, 2022
1 parent b61ed19 commit d5cf326
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions docs/development/test.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
<script class="mocha-exec">
mocha.run(failures => {
const result = failures === 0 ? 'PASS' : 'FAIL';
// If you change the next line, please modifiy the regexp in web-test/index.js
const status = result + ': ' + failures + ' failures. Peggy Version: ' + browser.peggyVersion()
console.log(status);
const div = document.getElementById('results');
Expand Down
2 changes: 1 addition & 1 deletion web-test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ async function main() {
page
.on("console", message => {
const txt = message.text();
const m = txt.match(/([A-Z]+): \d+ failures. Peggy Version: (.*)/);
const m = txt.match(/([A-Z]+): \d+ failures.\s+Peggy Version: (.*)/);
if (!m) {
console.error("Console:", txt);
return;
Expand Down

0 comments on commit d5cf326

Please sign in to comment.