mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-10 02:47:50 +00:00
Update tests for es6.
This commit is contained in:
@@ -154,13 +154,13 @@
|
|||||||
ui.isForeign = RegExp('^(\\w+:)?//').test(build);
|
ui.isForeign = RegExp('^(\\w+:)?//').test(build);
|
||||||
|
|
||||||
// Used to indicate testing a modularized build.
|
// Used to indicate testing a modularized build.
|
||||||
ui.isModularize = /\b(?:amd|commonjs|es6?|node|npm|(index|main)\.js)\b/.test([location.pathname, location.search]);
|
ui.isModularize = /\b(?:amd|commonjs|es|node|npm|(index|main)\.js)\b/.test([location.pathname, location.search]);
|
||||||
|
|
||||||
// Used to indicate testing in Sauce Labs' automated test cloud.
|
// Used to indicate testing in Sauce Labs' automated test cloud.
|
||||||
ui.isSauceLabs = location.port == '9001';
|
ui.isSauceLabs = location.port == '9001';
|
||||||
|
|
||||||
// Used to indicate that lodash is in strict mode.
|
// Used to indicate that lodash is in strict mode.
|
||||||
ui.isStrict = /\bes6?\b/.test([location.pathname, location.search]);
|
ui.isStrict = /\bes\b/.test([location.pathname, location.search]);
|
||||||
|
|
||||||
ui.urlParams = { 'build': build, 'loader': loader };
|
ui.urlParams = { 'build': build, 'loader': loader };
|
||||||
ui.timing = { 'loadEventEnd': 0 };
|
ui.timing = { 'loadEventEnd': 0 };
|
||||||
|
|||||||
@@ -131,8 +131,8 @@
|
|||||||
var ui = root.ui || (root.ui = {
|
var ui = root.ui || (root.ui = {
|
||||||
'buildPath': filePath,
|
'buildPath': filePath,
|
||||||
'loaderPath': '',
|
'loaderPath': '',
|
||||||
'isModularize': /\b(?:amd|commonjs|es6?|node|npm|(index|main)\.js)\b/.test(filePath),
|
'isModularize': /\b(?:amd|commonjs|es|node|npm|(index|main)\.js)\b/.test(filePath),
|
||||||
'isStrict': /\bes6?\b/.test(filePath),
|
'isStrict': /\bes\b/.test(filePath),
|
||||||
'urlParams': {}
|
'urlParams': {}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -8165,7 +8165,7 @@
|
|||||||
QUnit.test('should return `false` if `Buffer` is not defined', function(assert) {
|
QUnit.test('should return `false` if `Buffer` is not defined', function(assert) {
|
||||||
assert.expect(1);
|
assert.expect(1);
|
||||||
|
|
||||||
if (Buffer && lodashBizarro) {
|
if (!isStrict && Buffer && lodashBizarro) {
|
||||||
assert.strictEqual(lodashBizarro.isBuffer(new Buffer(2)), false);
|
assert.strictEqual(lodashBizarro.isBuffer(new Buffer(2)), false);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|||||||
Reference in New Issue
Block a user