javascript Defensive coding with guard assertions in Javascript Let’s take a look at a function that took a score between 1 and 100 and returned a rating out of 5. function rating(score) { return Math.ceil(score / 20); }At first glance, this function looks simple, it has made a lot of
angularjs Setting up mocha for testing AngularJS in Visual Studio using sinon, and chai I decided to start a new asp.net mvc project with web api and use a bit of angularjs functionality. I had heard about mocha testing library which you can use do a tdd style development for my angularjs codes. I saw this pluraral