<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Testing on Maarten on IT</title><link>https://maarten.mulders.it/categories/testing/</link><description>Recent content in Testing on Maarten on IT</description><generator>Hugo</generator><language>en-us</language><copyright>&amp;copy; 2013 - 2026 Maarten Mulders</copyright><lastBuildDate>Tue, 07 Jan 2025 12:55:20 +0100</lastBuildDate><atom:link href="https://maarten.mulders.it/categories/testing/index.xml" rel="self" type="application/rss+xml"/><item><title>Mutation Testing badge with PIT and Stryker Dashboard</title><link>https://maarten.mulders.it/2022/07/mutation-testing-badge-with-pit-and-stryker-dashboard/</link><pubDate>Sat, 30 Jul 2022 10:41:13 +0200</pubDate><guid>https://maarten.mulders.it/2022/07/mutation-testing-badge-with-pit-and-stryker-dashboard/</guid><description>&lt;p&gt;Earlier, I wrote about integrating PIT with the Stryker Mutator Dashboard.
The setup for that was pretty complicated, with some shell scripting that extracted the JSON payload for the report from a JavaScript file.
Today, I&amp;rsquo;m introducing a much simpler approach to that: the &lt;strong&gt;Stryker Mutator Dashboard reporter for PIT&lt;/strong&gt;.&lt;/p&gt;</description></item><item><title>Mutation Testing badge with Pitest and Stryker Dashboard</title><link>https://maarten.mulders.it/2020/06/mutation-testing-badge-with-pitest-and-stryker-dashboard/</link><pubDate>Tue, 30 Jun 2020 13:18:13 +0200</pubDate><guid>https://maarten.mulders.it/2020/06/mutation-testing-badge-with-pitest-and-stryker-dashboard/</guid><description>&lt;p&gt;Over the years, badges have become a way for open source maintainers to show the state of their product.
Badges can give a quick overview of the code quality, test coverage or build health of an open-source product.
The problem with code coverage is, however, that a high coverage doesn&amp;rsquo;t mean the tests are any &lt;em&gt;good&lt;/em&gt;.
If only there was a way to show the quality of the test suite&amp;hellip;&lt;/p&gt;</description></item><item><title>Reports from Devoxx PL</title><link>https://maarten.mulders.it/2019/06/reports-from-devoxx-pl/</link><pubDate>Tue, 25 Jun 2019 14:00:13 +0200</pubDate><guid>https://maarten.mulders.it/2019/06/reports-from-devoxx-pl/</guid><description>&lt;p&gt;From yesterday until tomorrow I&amp;rsquo;m attending &lt;a href="https://www.devoxx.pl/"&gt;Devoxx Poland&lt;/a&gt; (or Devoxx PL for short).
It&amp;rsquo;s the second largest conference in the Devoxx family with around 2700 people attending.
The conference is held in the &lt;a href="https://www.icekrakow.pl/"&gt;ICE Kraków Congress Centre&lt;/a&gt;, a large venue with an amazing primary room.&lt;/p&gt;






 
 
 
 

 
 
 &lt;div class="flex justify-center items-center"&gt;
 &lt;figure class="rounded-lg "&gt;
 
 &lt;picture class="rounded-lg "&gt;
 &lt;source srcset="https://maarten.mulders.it/2019/06/reports-from-devoxx-pl/IMG_20190624_121320_hu_db4e3c5766a00d69.webp" alt="Entrance of the ICE" type="image/webp" width="4608" height="2112" class="justify-center shadow-lg"&gt;
 &lt;img src="https://maarten.mulders.it/2019/06/reports-from-devoxx-pl/IMG_20190624_121320_hu_a410d4a39c14c204.jpg" alt="Entrance of the ICE" type="image/jpeg" width="4608" height="2112" class="justify-center shadow-lg"&gt;
 &lt;/picture&gt;
 
 &lt;figcaption class="text-center"&gt;Entrance of the ICE&lt;/figcaption&gt;
 &lt;/figure&gt;
 &lt;/div&gt;
 
 



&lt;p&gt;The main reason I&amp;rsquo;m here is to give a talk about GraalVM on Wednesday morning.
Apart from that, it&amp;rsquo;s a nice opportunity to network, meet old friends and make new ones.
And of course to attend other talks to learn something new.&lt;/p&gt;</description></item><item><title>Verify logging with Logback</title><link>https://maarten.mulders.it/2017/03/verify-logging-with-logback/</link><pubDate>Thu, 02 Mar 2017 10:15:32 +0200</pubDate><guid>https://maarten.mulders.it/2017/03/verify-logging-with-logback/</guid><description>&lt;p&gt;Sometimes you have a piece of logging that is very important, maybe even part of a business requirement.
In that case, you might want to verify that in a unit test, so you can rest assured that this requirement is actually met.
How to do that?&lt;/p&gt;
&lt;h3 id="mock-it-away"&gt;Mock it away&lt;/h3&gt;
&lt;p&gt;A first approach might be to just mock your logging framework in a unit test and verify it was called as you expected.
It might sound tempting, and easy to do, but &lt;a href="https://github.com/mockito/mockito/wiki/How-to-write-good-tests#dont-mock-type-you-dont-own"&gt;not everybody likes it&lt;/a&gt;.
And in fact, you might run into some issues when walking this path, because some libraries tend to make classes and/or methods final so they can&amp;rsquo;t always be mocked away.
Also, a lot of people tend to create a logger by doing &lt;code&gt;private static final Logger LOG = ...&lt;/code&gt;, which makes it even harder to mock it away.
Making your logger an instance variable just so you can test it? Nah&amp;hellip;&lt;/p&gt;</description></item></channel></rss>