Workflow

Practice disaster scenarios

Gustav Sundin
Practice disaster scenarios, at the very least as thought experiments. Some ideas to get you started: What happens if your Kubernetes cluster gets funked up? What do we do? Create a new one from scratch? Do we know how to do that? What happens if our production database gets corrupted? Do we have backups? And do we know how to restore one? Make sure to write down clear instructions beforehand so that some sleep-deprived on-call developers don’t cause even more harm by panicking when we have a real incident.

Code review reflections

Gustav Sundin
The quality of the code reviews within your organization will over time have an huge impact on the overall success of your business. Missing or poor code reviews will lead to deteriorating quality and much headache will follow, while good code reviews will ensure that your code base maintains a high and increasing quality. More importantly, code reviews also acts a way to share knowledge within the team. Therefore properly carried out code reviewing is one of the best, cheapest and fastest ways of acquiring skilled developers.

A successful testing strategy

Gustav Sundin
Today we will a closer look at the classic testing pyramid and see how we can transform that into a concrete strategy for how to write your tests. While the terminology I use is not exactly the same as the one used by Mike Cohn when he first described the testing pyramid in his book Succeeding with Agile, the core concepts remain the same – a strong foundation of unit tests, complemented with a sufficient number of component tests (which are similar to Cohn’s service tests) and sprinkled with a few end-to-end tests (which are called UI tests by Cohn) as a last line of defense.

Dockerized database testing

Gustav Sundin
In this post I am going to give you an overview of different approaches to use when unit testing your backend code and database calls. Background In my current project, we have a backend written in Go and a PostgreSQL database. We have for a long time been writing unit tests for the backend to be able to guarantee that the code is working as intended. In order to not have to rely on a database connection and be dependent on the state of the data in that database, we chose to mock away all database calls using a tool called go-sqlmock in the unit tests.

Unix tools

Gustav Sundin
What is commonly referred to as the Unix tools are a set of commands that are available on all Unix systems. Together, these form part of the basic toolkit for any serious software engineer. You should learn how to use these tools properly, as they can grant you an enormous boost in your daily workflow, and not the least when it comes to automating task and routines, such as in your team’s automated CI pipeline.