Merge /master into /no-chain

Former-commit-id: fcef4ca54be1907762e92ee528b650bea9759c1d
This commit is contained in:
John-David Dalton
2012-11-19 21:52:25 -08:00
14 changed files with 153 additions and 107 deletions

View File

@@ -1782,6 +1782,19 @@
deepEqual(_.toArray('abc'), ['a', 'b', 'c']);
deepEqual(_.toArray(Object('abc')), ['a', 'b', 'c']);
});
test('should work with a NodeList for `collection` (test in IE < 9)', function() {
if (window.document) {
try {
var nodeList = document.getElementsByTagName('body'),
body = nodeList[0],
actual = _.toArray(nodeList);
} catch(e) { }
deepEqual(actual, [body]);
} else {
skipTest();
}
});
}(1, 2, 3));
/*--------------------------------------------------------------------------*/