diff --git a/__tests__/src/getPropLiteralValue-test.js b/__tests__/src/getPropLiteralValue-test.js index c070be9..8db4845 100644 --- a/__tests__/src/getPropLiteralValue-test.js +++ b/__tests__/src/getPropLiteralValue-test.js @@ -427,4 +427,13 @@ describe('getLiteralPropValue', () => { assert.deepEqual(expected, actual); }); }); + + it('should return an empty array provided an empty array in props', () => { + const prop = extractProp('
'); + + const expected = []; + const actual = getLiteralPropValue(prop); + + assert.deepEqual(expected, actual); + }); }); diff --git a/__tests__/src/getPropValue-test.js b/__tests__/src/getPropValue-test.js index 4ff2a9a..9a7be4f 100644 --- a/__tests__/src/getPropValue-test.js +++ b/__tests__/src/getPropValue-test.js @@ -780,4 +780,13 @@ describe('getPropValue', () => { assert.deepEqual(expected, actual); }); }); + + it('should return an empty array provided an empty array in props', () => { + const prop = extractProp('
'); + + const expected = []; + const actual = getPropValue(prop); + + assert.deepEqual(expected, actual); + }); });