From 50ce8d002c96269b05816c0ab5b59e9d5e38358b Mon Sep 17 00:00:00 2001 From: Michael Frank Date: Sat, 29 May 2021 07:26:28 +1200 Subject: [PATCH 1/2] helloWorld.spec.js: Fix disparity between the README example and actual test. --- helloWorld/helloWorld.spec.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/helloWorld/helloWorld.spec.js b/helloWorld/helloWorld.spec.js index 7f9198d..89cd731 100644 --- a/helloWorld/helloWorld.spec.js +++ b/helloWorld/helloWorld.spec.js @@ -1,5 +1,7 @@ const helloWorld = require('./helloWorld'); -test('says "Hello, World!"', function() { - expect(helloWorld()).toBe("Hello, World!"); +describe('Hello World', function() { + test('says "Hello, World!"', function() { + expect(helloWorld()).toBe('Hello, World!'); + }); }); From f8a2928882e28e824a623b5098987349fb68caf8 Mon Sep 17 00:00:00 2001 From: Michael Frank Date: Sat, 29 May 2021 07:55:43 +1200 Subject: [PATCH 2/2] Also update the actual spec file. --- helloWorld/helloWorld.spec.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/helloWorld/helloWorld.spec.js b/helloWorld/helloWorld.spec.js index 89cd731..e6030fd 100644 --- a/helloWorld/helloWorld.spec.js +++ b/helloWorld/helloWorld.spec.js @@ -2,6 +2,6 @@ const helloWorld = require('./helloWorld'); describe('Hello World', function() { test('says "Hello, World!"', function() { - expect(helloWorld()).toBe('Hello, World!'); + expect(helloWorld()).toEqual('Hello, World!'); }); });