Test case details

Preparation Code

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script> <p id="foo">   Test </p> <p id="bar">   bars</p>

Test cases

Test #1

document.getElementById('foo'); document.getElementById('bar');

Test #2

function _(id) {   return document.getElementById(id); } _("foo"); _("bar");

Test #3

function _(id) {   return $(document.getElementById(id)); } _('foo'); _('bar');

Test #4

function _(id) {   return $(document.getElementById(id)); } $(_('foo')); $(_('bar'));

Test #5

$('#foo'); $('#bar');