From 81b88d220ff7d9454a0572b16c9417b1a9ad4335 Mon Sep 17 00:00:00 2001 From: BKinahan Date: Wed, 23 Dec 2015 23:10:48 +0000 Subject: [PATCH] Add test for functionality of public methods --- .../object-oriented-and-functional-programming.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/seed/challenges/01-front-end-development-certification/object-oriented-and-functional-programming.json b/seed/challenges/01-front-end-development-certification/object-oriented-and-functional-programming.json index c57bd8080f..4407367b02 100644 --- a/seed/challenges/01-front-end-development-certification/object-oriented-and-functional-programming.json +++ b/seed/challenges/01-front-end-development-certification/object-oriented-and-functional-programming.json @@ -267,7 +267,8 @@ "tests": [ "assert(typeof myBike.getGear !== 'undefined' && typeof myBike.getGear === 'function', 'message: The method getGear of myBike should be accessible outside the object.');", "assert(typeof myBike.setGear !== 'undefined' && typeof myBike.setGear === 'function', 'message: The method setGear of myBike should be accessible outside the object.');", - "assert(typeof myBike.gear === 'undefined', 'message: myBike.gear should remain undefined.');" + "assert(typeof myBike.gear === 'undefined', 'message: myBike.gear should remain undefined.');", + "assert.strictEqual((function () { myBike.setGear(4); return myBike.getGear(); })(), 4, 'message: myBike.getGear() should return 4 after myBike.setGear(4).');" ], "challengeSeed": [ "var Car = function() {",