Browse Source

Tests(DPxAI): update test for quest01 objects-around

pull/2706/head
Louis TOUSSAINT 3 months ago committed by Oumaima Fisaoui
parent
commit
52dc2a61dc
  1. 16
      js/tests/objects-around.json

16
js/tests/objects-around.json

@ -1,19 +1,19 @@
[ [
{ {
"description": "variable robot is declared and of type object", "description": "variable myRobot is declared and of type object",
"code": "equal(typeof robot, 'object')" "code": "let robot = {\n name: 'Freddy',\n age: 27,\n hasEnergy: false,\n}\n\n// Your code\n\nequal(typeof myRobot, 'object')"
}, },
{ {
"description": "property name from robot is of type string", "description": "property name from myRobot is of type string",
"code": "equal(typeof robot.name, 'string')" "code": "let robot = {\n name: 'Freddy',\n age: 27,\n hasEnergy: false,\n}\n\n// Your code\n\nequal(typeof myRobot.name, 'string')"
}, },
{ {
"description": "property age from robot is of type number", "description": "property age from myRobot is of type number",
"code": "equal(typeof robot.age, 'number')" "code": "let robot = {\n name: 'Freddy',\n age: 27,\n hasEnergy: false,\n}\n\n// Your code\n\nequal(typeof myRobot.age, 'number')"
}, },
{ {
"description": "property hasEnergy from robot is of type boolean", "description": "property hasEnergy from myRobot is of type boolean",
"code": "equal(typeof robot.hasEnergy, 'boolean')" "code": "let robot = {\n name: 'Freddy',\n age: 27,\n hasEnergy: false,\n}\n\n// Your code\n\nequal(typeof myRobot.hasEnergy, 'boolean')"
}, },
{ {
"description": "all 3 variable should be defined and have the right values", "description": "all 3 variable should be defined and have the right values",

Loading…
Cancel
Save