Replace var to const in Libraries/Utilities/deepFreezeAndThrowOnMutationInDev-test.js (#22110)
Summary: Replaces the keywords var to const in Libraries/Utilities/deepFreezeAndThrowOnMutationInDev.js - [x] Check npm run flow - [x] Check npm run flow-check-ios - [x] Check npm run flow-check-android [GENERAL] [ENHANCEMENT] [Libraries/Utilities/deepFreezeAndThrowOnMutationInDev.js] - replace var Pull Request resolved: https://github.com/facebook/react-native/pull/22110 Differential Revision: D12919284 Pulled By: TheSavior fbshipit-source-id: 4a3a3f4c49665c538ed5f38f3cc2142d40ac4d55
This commit is contained in:
parent
6ebee18d13
commit
e835c6dc50
|
@ -28,7 +28,7 @@ describe('deepFreezeAndThrowOnMutationInDev', function() {
|
|||
|
||||
it('should not throw on object without prototype', () => {
|
||||
__DEV__ = true;
|
||||
var o = Object.create(null);
|
||||
const o = Object.create(null);
|
||||
o.key = 'Value';
|
||||
expect(() => deepFreezeAndThrowOnMutationInDev(o)).not.toThrow();
|
||||
});
|
||||
|
@ -134,7 +134,7 @@ describe('deepFreezeAndThrowOnMutationInDev', function() {
|
|||
expect(o.key1.key2).toBe('newValue');
|
||||
});
|
||||
|
||||
it("shouldn't recurse infinitely", () => {
|
||||
it('shouldn\'t recurse infinitely', () => {
|
||||
__DEV__ = true;
|
||||
const o = {};
|
||||
o.circular = o;
|
||||
|
|
Loading…
Reference in New Issue