From e789c1f683195e2597cff15749ee4a424a4f3e98 Mon Sep 17 00:00:00 2001 From: Alec Larson <1925840+aleclarson@users.noreply.github.com> Date: Tue, 25 Jun 2024 20:25:58 -0400 Subject: [PATCH] test: crush with dot in property name --- src/object/tests/crush.test.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/object/tests/crush.test.ts b/src/object/tests/crush.test.ts index 3a563709c..d55090914 100644 --- a/src/object/tests/crush.test.ts +++ b/src/object/tests/crush.test.ts @@ -33,4 +33,12 @@ describe('crush function', () => { timestamp: now }) }) + test('handles property names with dots', () => { + const obj = { + a: { 'b.c': 'value' } + } + expect(_.crush(obj)).toEqual({ + 'a.b.c': 'value' + }) + }) })