Fix build test for older Node versions w/o setImmediate.

Former-commit-id: 9f21f174626cd86eefd0a26cf0b36a60858ba501
This commit is contained in:
John-David Dalton
2013-05-30 09:37:09 -04:00
parent 6446daf1a6
commit eccab3cd57

View File

@@ -1535,7 +1535,7 @@
vm.runInContext(data.source, context, true);
var lodash = context._;
if (methodName == 'chain' || methodName == 'defer' || methodName == 'findWhere') {
if (methodName == 'chain' || methodName == 'findWhere' || (methodName == 'defer' && global.setImmediate)) {
notEqual(strip(lodash[methodName]), strip(_[methodName]), basename);
} else if (!/\.min$/.test(basename)) {
equal(strip(lodash[methodName]), strip(_[methodName]), basename);