Focus

Testing

Articles, podcasts, talks, and more about Testing.
Blog Post

Testing your GitLab CI/CD pipeline

If you develop a pipeline as a service for other development teams you should treat it as a product and establish product development processes, a versioning strategy, etc. around it. Besides that, as potentially many teams will use and rely on your pipeline you want to make sure that new features don’t break existing functionality. This ensures that your customer base remains happy and able to deliver business value. Therefore you need some sort of testing and we will demonstrate a way to (integration-) test your GitLab CI/CD pipeline.

Article

Containers for tests and local development with Spring Boot 3.1

Spring Boot 3.1.0, the most recent minor release of Spring Boot 3, appeared in May. In this article, we will be taking a look at how the new support for Testcontainers and Docker Compose can help us with tests and local development.

Article

Testing in Spring Boot applications

Slice it up, please

Article

An Introduction to TLA+ and Its Use in Parties

TLA+ is a system for modeling all possible states of a system. On this model, you can then verify certain properties of this system. Smart people can use this to check that their thread scheduling runs all threads equally, or that their work queue will never overflow. In this article, we’ll try and verify the fraught process of ordering pizza for a pizza party as a small introduction to the concepts and syntax of TLA+.

Article

Property-based Testing with “fast-check”

It isn’t exactly news that developers have to write not only code but also tests. Nevertheless, many find this to be burdensome and monotonous work. Plus, it is far from guaranteed that unit tests actually cover all the border and non-border cases. A modern approach is property-based testing, which consists of specifying an abstract condition that is then automatically checked by the test framework.

Article

Diverse Themen und Bibliotheken für Tests in und mit Java

Eine bunte Tüte Gemischtes rund um Tests

Blog Post

Test organization and naming

As our system grows, so will our test suites. For our production code, we have learned techniques to keep it maintainable. For example, we try to structure our logic into sub-aspects, put them in specific locations and give the units meaningful names. We want to achieve the same for our tests. One of the main goals is that a developer - or generally speaking, the person who has to maintain the test - knows where to find which test. We also want to understand as quickly as possible what the test is for and what might be the reason for a failing test.

Blog Post

Test Strategy

In our previous posts, we focused on why and how we write tests. In most of our projects, there will be many of those tests. In the last post about tests granularity, we additionally stated that there usually will be different kinds of tests, on different levels of granularity. That leads to our next topic: which kinds of tests do we need and what is the ideal mix of them?

Blog Post

Tests Granularity

Blog Post

Anatomy of a Good Test

In our last post, we focused on why we should write tests and what value they provide. This time we will go far more technical and take a look at a single test. We will show what makes a test a good one and describe desired and unwanted properties. Interestingly enough, all those properties hold, no matter how isolated or integrated the test is. This already gives us a hint that all tests are alike, we should remember that. Unfortunately, as the topic is very broad, we will have to skip some aspects that play a role when we’re talking about test suites. We will get back to them in one of our next posts.

Blog Post

Why you should write automated tests

This blog post gives an overview of the most common benefits gained by writing automated tests. It starts in a place where most of the projects we’ve seen so far are: tests are written as a last step of the development process. Then it shows additional benefits that could be gained if we all gave the tests a bit more focus and care.

Blog Post

Cross-platform testing of TypeScript code with Jasmine and Karma

Blog Post

About unit and integration tests

The terms unit test and integration test are typically used as something different, or even opposite. In this blog post I explain why this is misleading and how I prefer to talk about isolation vs. integration instead.

Blog Post

What Could Possibly Go Wrong

What could possibly go wrong if you put Clojure 1.10 and Scala 2.13 on the same classpath? We’re about to find out.

Article

JUnit5 für das Testen von Spring Boot-Anwendungen

Das perfekte Doppel

Podcast

Testen von Microservices

Erfahrungen mit End-to-End Tests

Blog Post

Testen von Microservice-Systemen

Automatisiertes Testen ist in der Softwareentwicklung mittlerweile ein Standardvorgehen. Im Kontext eines verteilten Microservice-Systems wird üblicherweise das korrekte Verhalten jedes einzelne Services mit Hilfe von Unit-, Integrations- und End-2-End Tests verifiziert. Wie aber kann das Zusammenspiel der einzelnen Services getestet und sichergestellt werden? Die Idee, End-2-End Tests des Gesamtsystems zu erstellen, ist naheliegend. Ist dies aber sinnvoll, oder gibt es andere, besser geeignete Ansätze?

Article

Java-Bibliotheken für den Einsatz in Tests

Testunterstützung

Blog Post

Testing is storytelling

Tests do not only exist to verify the absence of known bugs. They’re also documenting the expected behaviour of a system. Moreover, they’re showing developers how to use code.

Article

Generierung von Regressionstests für Legacy-Code

In diesem Artikel geht es um die Möglichkeit, bei Legacy-Anwendungen Regressionstests anhand des Quellcodes zu generieren, um vor einem möglichen Refactoring Tests erzeugt zu haben. Diese sollen sicherstellen, dass die Anwendung nach dem Refactoring noch genauso funktioniert wie vorher. Hier gibt es einige interessante Ansätze und auch einige Tools, die diese implementieren. Der Artikel zeigt zwei mögliche Ansätze.

Blog Post

A Playground for Testing OpenID Connect

Solving problems we wish we didn’t have

Blog Post

Spring-less testing

Spring is a great project, it helps a lot with common, usually mundane, tasks. But it’s not always unicorns and rainbows. Too much Spring in tests can cause a few issues like long execution time and fragility. Here, I’m showing how to avoid such pitfalls.

Article

Consumer-Driven Contracts – Testen von Schnittstellen innerhalb einer Microservices-Architektur

In einer Microservices-Architektur entstehen viele Services – potenziell in den verschiedensten Programmiersprachen. Um eine reibungslose Kommunikation zwischen diesen zu gewährleisten, müssen die Schnittstellen passen und auch über längere Zeit stabil bleiben. Consumer-Driven Contracts stellt hierzu einen Ansatz dar, der zudem die Schnittstellen und deren Aufrufer noch zusätzlich testet.

Article

Auf Nummer sicher

Testen von ausführbaren Geschäftsprozessen

Article

Testobjekt: Geschäftsprozess – Testen für kontinuierliche Verbesserung

Die Automatisierung von Geschäftsprozessen mittels WS-BPEL oder BPMN 2.0 steht in der heutigen Zeit oftmals im Focus der IT-Strategien von Unternehmen. Geschäftsprozesse werden dabei nicht mehr nur fachlich modelliert, sondern so formal beschrieben, dass sie mittels Prozess-Engines ausgeführt werden können. Diese formalen Modelle sind zwar abstrakter und näher an den fachlichen Geschäftsprozessen als normale Programme, sind aber trotzdem Softwareartefakte, die während der einzelnen Entwicklungszyklen und auch bei späteren Anpassungsarbeiten getestet werden müssen.