Skip to content
Permalink
Browse files

Tests: Bring back some of the clean-up logic

  • Loading branch information
markelog committed Apr 5, 2014
1 parent 4f14bea commit 1dedd3185ea1e9853a2ce26ef3051c63201b4533
Showing with 11 additions and 0 deletions.
  1. +11 −0 test/data/testrunner.js
@@ -138,8 +138,19 @@ window.moduleTeardown = function() {
}
};

QUnit.done(function() {
// Remove our own fixtures outside #qunit-fixture
supportjQuery( "#qunit ~ *" ).remove();
});

QUnit.testDone(function() {

// Ensure jQuery events and data on the fixture are properly removed
jQuery( "#qunit-fixture" ).empty();
// ...even if the jQuery under test has a broken .empty()
supportjQuery( "#qunit-fixture" ).empty();


// Reset internal jQuery state
jQuery.event.global = {};
if ( ajaxSettings ) {

0 comments on commit 1dedd31

Please sign in to comment.
You can’t perform that action at this time.