If anyone understands the tests, please tell me how I can implement test for two things:
1) Was obj.newRing method called, when makeRing function starts. 2) whether the parameter 'num' is passed to the function makeRing(num) is Matches with the property of the object passed in obj.newRing ({number: num}).
function makeRing (num) {
currRing = obj.newRing ({number: num});
}
Maybe someone will have some ideas how to use sinon or else in this situation, I will be glad of any information. I suffer for a long time ... All thanks!