7 advices to make your unit tests really useful, optimised and maintainable.

Photo by Chenyu Guan on Unsplash

Let me guess… You are a software engineer and you are aware of the importance of automated tests. They allow you to sleep well and to be confident when you deploy your code or when you do a demo of your most recent developed features. They let anyone who modifies the code knows whether they’ve broken something.

Implementing unit tests is a good starting point. Implementing them correctly is better.

This article deals with some guidelines to help you to write useful and efficient unit tests. It allows you to avoid debugging files of several hundreds of lines during hours…

How to take advantage of Event Sourcing.

Event Sourcing is a powerful design that enables reliable, mutable, and scalable systems.
This article doesn’t deal with the basics of this approach. It aims at providing some patterns and guidelines for proper implementation.

The main principle of Event Sourcing

The state of any system can be seen as the outcome of all past mutations to the initial state.
Events are responsible for triggering state mutations.

Photo by Manson Yim on Unsplash

Let’s start with some definitions

Note: These definitions are valid within the context of the article. They do not aim at being universal.

Component: Any piece of software. …

Photo by Denys Nevozhai on Unsplash

This article will help you to:

  • keep the code readable and sustainable,
  • structure the code with normalized patterns and schemes,
  • manage the JS asynchronous flow execution and avoid callback hell.

Software patterns

Rope and nodes

Pierre Gendre

Software engineer with a passion for physics, meditation, history, mathematics and martial arts. I like the smell of the air when it’s about to snow.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store