From 5d305c3225907bf5490fa197136ecddd50c0f306 Mon Sep 17 00:00:00 2001 From: Mark Tyers Date: Sun, 15 Sep 2019 15:42:03 +0100 Subject: [PATCH] replaced a matcher --- exercises/07_unit_testing/database/unit tests/todo.spec.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/exercises/07_unit_testing/database/unit tests/todo.spec.js b/exercises/07_unit_testing/database/unit tests/todo.spec.js index 10086e5f..60268721 100644 --- a/exercises/07_unit_testing/database/unit tests/todo.spec.js +++ b/exercises/07_unit_testing/database/unit tests/todo.spec.js @@ -45,11 +45,10 @@ describe('add()', () => { // ACT await todo.add('bread', 4) await todo.add('bread', 2) - const count = await todo.countItems() const data = await todo.getAll() const qty = data[0].qty - // ASSERT (note there are two assertions as stated on line 50) - expect(count).toBe(1) + // ASSERT (note there are two assertions as stated on line 42) + expect(data).toHaveLength(1) expect(qty).toEqual(6) done() })