Blog.
Hi, my name is Marco. Working as a Senior Software Architect at Philips. I'm an Opensource Maintainer and Contributor. If you like my work, consider to sponsor my work.
I wrote my first blog March 2011. Mostly I'm writing on software development. In total I wrote 75 articles in 7 categories. Use search below to filter by title or click a category or tag to filter by tag or category.
Categories:
Tags:
Zero-trustSpiffeVaultSigstoreDockerSLSAGitHubGitHelmKubernetesTraefikTerraformsshReactNext.jsHexoBlogMarkdownNginxElasticsearchWebTLSLetsencryptHTTP/2WindowsRaspberry PiraspbiantestTDDbenchmarkconcurrencyparallelismbootChocolateyGradleJavaHTML5PWASEOPerformanceVirtualBoxAngularNode.jsazurehaproxysynologyvagranthyper-vBDDJasmineMochaKarmaPuTTYDebianpacker.ioChaiGruntSinonnpmJenkinsMSBuildMSpecOpenCoverNuGetArchitecturec#CQRSDesign patternsFluent SecurityJSONKnockoutJSMicrosoftPowerShellWindows 8Windows PhoneWindsorMVVMMVC3SecurityEntity FrameworklinqvhdConvincingElevator pitchSoftskillsAMDjQueryNcqrsdiskpartvdiskDDDFakeItEasyUnittestingDependency InjectionKinect
Stories
Using Mocha Chai Sinon to test Node.js
Marco Franssen /
In this article I'm going to show you how to write tests for your NodeJS application using Mocha, Chai and Sinon. Mocha is a feature-rich JavaScript test framework running on node.js and the browser, making asynchronous testing simple and fun. Mocha tests run serially, allowing for flexible and accurate reporting, while mapping uncaught exceptions to the correct test cases. One of the cool things is you can choose your own assertion style when writing Mocha tests. In this article I will use Ch…