Skip to content

Instantly share code, notes, and snippets.

@Potherca
Last active February 6, 2018 05:13
Show Gist options
  • Save Potherca/8579269 to your computer and use it in GitHub Desktop.
Save Potherca/8579269 to your computer and use it in GitHub Desktop.
Add the ability to mark tests in QUnit as skipped.
/*global QUnit, window, document*/
(function (QUnit, window, document) {
'use strict';
QUnit.testSkip = function (p_sTestName) {
QUnit.test(p_sTestName + ' (SKIPPED)', 0, function () {
var li = document.getElementById(QUnit.config.current.id);
QUnit.done(function () {
li.style.background = '#FFFF99';
});
});
};
window.testSkip = QUnit.testSkip;
}(QUnit, window, document));
/* EOF */
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment