Home » Testing » Page 8

Tag Archives: Testing

Blow up Your JUnit5 Tests with Permutations

Writing JUnit tests can be a tedious and boring process. Learn how you can improve your tests classes using permutations in combination with TestFactory methods and DynamicTest objects with a minimum of coding effort. In this article, I will use the Java stream ORM Speedment because it includes a ready-madePermutation class and thereby helps me save development time. Speedment otherwise allows database tables ...

Read More »

Testing Kotlin with Spock Part 3 – Interface default method

Kotlin allows you to put method implementation in an interface. The same mechanism can be found in Java interfaces as default methods (and also Groovy or Scala traits). Let’s see the difference between the Kotlin and Java default methods in interface by testing it with Groovy and Spock. What do we want to test? We often have an interface for ...

Read More »

The Truth About AI and Test Automation

Software testing has gradually evolved in the past few decades. In the past, teams were accustomed to the waterfall methodology: Everything was sequential, from requirements to product deployment. Only after the development phase was completed did the testers got their hands on the product. Historically, testers would find a number of bugs in this phase, and it would take a ...

Read More »

ActiveMQ Performance Testing


We use ActiveMQ as our messaging layer – sending large volumes of messages with a need for low-latency. Generally it works fine, however in some situations we’ve seen performance problems. After spending too much time testing our infrastructure I think I’ve learned something interesting about ActiveMQ: it can be really quite slow. Although in general messages travel over ActiveMQ without ...

Read More »

Java: Mocking a ResultSet using Mockito

This post shows how you can mock a java.sql.ResultSet using Mockito. It can be used to help unit test code which performs operations on ResultSets (such as a ResultSetExtractor) without relying on an external datasource. You can create a MockResultSet by providing a list of column names and a 2D array of data. For example: var rs = MockResultSet.create( new ...

Read More »

Spock 1.2 – hassle-free Spring beans mocking in integration tests


Discover how to automatically inject Spock’s mocks and spies into the Spring context using Spock 1.2. Stubs/mocks/spies in Spock (and their life cycle) have been always tightly coupled with the Spock Specification class. It was only possible to create them in a test class. Therefore, using shared, predefined mocks (in both unit and integration tests) was problematic. The situation was ...

Read More »

7 Bad Habits to Avoid as a QA Engineer

Most people would agree that software quality is important. We have seen the results of buggy software in all kinds of situations: from Mars probes malfunctioning and chemotherapy machines administering lethal doses of radiation, to telecommunications systems experiencing a cascade failure. It would seem logical to assume that software testers would be much-valued members of a development team. Yet sadly, ...

Read More »

The Importance of Application Decomposition in App Performance Testing

Discover faster, more efficient performance monitoring with an enterprise APM product learning from your apps. Take the AppDynamics APM Guided Tour! Summary Learn how to maximize the quality of your metric data by breaking down your app and applying proper instrumentation. DevOps is changing the way companies develop and maintain software. By embedding operations engineers into software development teams, companies ...

Read More »

A canonical XML test

I recently did a few days of TDD training for a client. They asked me to help them test and refactor a class that created XML from an internal domain model. This gave me the opportunity to examine a bigger pattern. I wondered where the domain model came from. Looking through the code base, I found that the same or ...

Read More »