From 82edc131b0854a191e31f722a50d44c1d299ba8a Mon Sep 17 00:00:00 2001 From: Tim Yung Date: Fri, 9 Jun 2017 15:55:54 -0700 Subject: [PATCH] RN: Fix deepFreezeAndThrowOnMutationInDev-test for Node v8.1.0 Reviewed By: raluca-elena Differential Revision: D5222219 fbshipit-source-id: e34903a506b8e6e0c81e1c21fd9e8e015b25b2d7 --- .../__tests__/deepFreezeAndThrowOnMutationInDev-test.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Libraries/Utilities/__tests__/deepFreezeAndThrowOnMutationInDev-test.js b/Libraries/Utilities/__tests__/deepFreezeAndThrowOnMutationInDev-test.js index 2d35d656f..e634d3949 100644 --- a/Libraries/Utilities/__tests__/deepFreezeAndThrowOnMutationInDev-test.js +++ b/Libraries/Utilities/__tests__/deepFreezeAndThrowOnMutationInDev-test.js @@ -79,7 +79,9 @@ describe('deepFreezeAndThrowOnMutationInDev', function() { var o = {oldKey: 'value'}; deepFreezeAndThrowOnMutationInDev(o); expect(() => { o.newKey = 'value'; }) - .toThrowError('Can\'t add property newKey, object is not extensible'); + .toThrowError( + /(Cannot|Can't) add property newKey, object is not extensible/ + ); expect(o.newKey).toBe(undefined); });