You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Checked next-gen ES issues and syntax problems by using the same environment and/or transpiler configuration without Mocha to ensure it isn't just a feature that actually isn't supported in the environment in question or a bug in your code.
'Smoke tested' the code to be tested by running it outside the real test suite to get a better sense of whether the problem is in the code under test, your usage of Mocha, or Mocha itself
Ensured that there is no discrepancy between the locally and globally installed versions of Mocha. You can find them with: node node_modules/.bin/mocha --version(Local) and mocha --version(Global). We recommend avoiding the use of globally installed Mocha.
Description
HTML-Reporter filters does not unhide all hidden suites
Steps to Reproduce
Run tests using the html reporter - click on the passes / failures filters
Expected behavior: [What you expect to happen]
When clicking on a filter twice all suites should be visible
Actual behavior: [What actually happens]
Only the odd numbered of the hidden reappears
Reproduces how often: [What percentage of the time does it reproduce?]
100% It happens every time
Versions
Additional Information
While working on making a html-electron reporter I noticed this issue.
The function unhide() only un-hides the odd numbered hidden suites.
The problem is the mutation of the html collection as the parameters used for selecting the elements are removed from said elements.
This is the working solution I arrived at.
/** * Unhide .hidden suites. */functionunhide(){varels=document.getElementsByClassName('suite hidden');// as the search criterion is changed the elements are removed from the collectionwhile(els[0]){els[0].className=els[0].className.replace('suite hidden','suite');}// *** This only removes the odd numbered ***// for (var i = 0; i < els.length; ++i) {// els[i].className = els[i].className.replace('suite hidden', 'suite');// }}
The text was updated successfully, but these errors were encountered:
Prerequisites
common mistake
labelnode node_modules/.bin/mocha --version
(Local) andmocha --version
(Global). We recommend avoiding the use of globally installed Mocha.Description
HTML-Reporter filters does not unhide all hidden suites
Steps to Reproduce
Run tests using the html reporter - click on the passes / failures filters
Expected behavior: [What you expect to happen]
When clicking on a filter twice all suites should be visible
Actual behavior: [What actually happens]
Only the odd numbered of the hidden reappears
Reproduces how often: [What percentage of the time does it reproduce?]
100% It happens every time
Versions
Additional Information
While working on making a html-electron reporter I noticed this issue.
The function unhide() only un-hides the odd numbered hidden suites.
The problem is the mutation of the html collection as the parameters used for selecting the elements are removed from said elements.
This is the working solution I arrived at.
The text was updated successfully, but these errors were encountered: