mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-06 01:47:48 +00:00
Fix Safari 9.0 flaky test fail.
This commit is contained in:
12
test/test.js
12
test/test.js
@@ -24210,18 +24210,12 @@
|
|||||||
QUnit.test('should preserve the sign of `0`', function(assert) {
|
QUnit.test('should preserve the sign of `0`', function(assert) {
|
||||||
assert.expect(1);
|
assert.expect(1);
|
||||||
|
|
||||||
var props = [-0, Object(-0), 0, Object(0)];
|
var props = [-0, Object(-0), 0, Object(0)],
|
||||||
|
expected = lodashStable.map(props, lodashStable.constant([true, false]));
|
||||||
var expected = [
|
|
||||||
[true, { '0': 'b' }],
|
|
||||||
[true, { '0': 'b' }],
|
|
||||||
[true, { '-0': 'a' }],
|
|
||||||
[true, { '-0': 'a' }]
|
|
||||||
];
|
|
||||||
|
|
||||||
var actual = lodashStable.map(props, function(key) {
|
var actual = lodashStable.map(props, function(key) {
|
||||||
var object = { '-0': 'a', '0': 'b' };
|
var object = { '-0': 'a', '0': 'b' };
|
||||||
return [_.unset(object, key), object];
|
return [_.unset(object, key), lodashStable.toString(key) in object];
|
||||||
});
|
});
|
||||||
|
|
||||||
assert.deepEqual(actual, expected);
|
assert.deepEqual(actual, expected);
|
||||||
|
|||||||
Reference in New Issue
Block a user