Permalink
Browse files

Fix #10931: Make unit tests work without web access.

  • Loading branch information...
gibson042 authored and dmethvin committed Jan 12, 2012
1 parent cc5e8e3 commit 6c8dd7e7d3a00133591d4f9c05c207900234e11e
Showing with 4 additions and 4 deletions.
  1. +2 −2 test/data/selector/sizzle_cache.html
  2. +2 −2 test/unit/selector.js
@@ -4,9 +4,9 @@
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
<title>jQuery selector - sizzle cache</title>
<script src="http://code.jquery.com/jquery-git.js"></script>
<script src="../include_js.php"></script>
<script>
var $git = jQuery.noConflict(true);
var $cached = jQuery.noConflict(true);
</script>
<script src="../include_js.php"></script>
@@ -133,10 +133,10 @@ testIframe("html5_selector", "attributes - jQuery.attr", function( jQuery, windo
});
testIframe("sizzle_cache", "Sizzle cache collides with multiple Sizzles on a page", function( jQuery, window, document ) {
var $git = window.$git;
var $cached = window.$cached;
expect(3);
deepEqual( $git('.test a').get(), [ document.getElementById('collision') ], "Select collision anchor with first sizzle" );
deepEqual( $cached('.test a').get(), [ document.getElementById('collision') ], "Select collision anchor with first sizzle" );
equal( jQuery('.evil a').length, 0, "Select nothing with second sizzle" );
equal( jQuery('.evil a').length, 0, "Select nothing again with second sizzle" );
});

0 comments on commit 6c8dd7e

Please sign in to comment.