From 3bf8c7bd09006028ba7b62d1fc87f45ba279c536 Mon Sep 17 00:00:00 2001 From: ztimson Date: Sun, 22 Sep 2024 03:13:22 -0400 Subject: [PATCH] Removed deep copy tests since it was replaced with a native function --- tests/object.spec.ts | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/tests/object.spec.ts b/tests/object.spec.ts index 5d97998..abd874d 100644 --- a/tests/object.spec.ts +++ b/tests/object.spec.ts @@ -29,28 +29,6 @@ describe('Object Utilities', () => { }); }); - describe('deepCopy', () => { - const copy = deepCopy(TEST_OBJECT); - test('Array of arrays', () => { - const a = [[1, 2], [3, 4]]; - const b = deepCopy(a); - b[0][1] = 5; - expect(a).not.toEqual(b); - }); - test('Change array inside object', () => { - copy.b[1] = [1, 1, 1]; - expect(copy.b[1]).not.toEqual(TEST_OBJECT.b[1]); - }); - test('Change object inside object', () => { - copy.g = {h: Math.random()}; - expect(copy.g).not.toEqual(TEST_OBJECT.g); - }); - test('Change object property inside nested array', () => { - copy.c.d[0][0].e = -1; - expect(copy.c.d[0][0].e).not.toEqual(TEST_OBJECT.c.d[0][0].e); - }); - }); - describe('dotNotation', () => { test('no object or properties', () => { expect(dotNotation(undefined, 'z')).toStrictEqual(undefined);