Building assertions with Strikt
Strikt is assertion library built for Kotlin with API which allows building multi assertions and gives us readable assertion errors.
Fighting Testing Boilerplate with IntelliJ IDEA Live Templates
Writing tests involves repeating some patterns over and over again. IntelliJ IDEA can shorten the process of test creation with the help of live templates.
How to test a time-dependent coroutine
The issue Unit testing is the fastest way to check if some piece of our application works as we expect. But what if we have to test some features that strongly depend on time? Should we allow our tests execute for instance for few minutes? Of course we shouldn’t! In this blog post I will […]
IntelliJ Live Template that makes my life little easier
IntelliJ is great tool for developer productivity. Check how can we adjust IDE to our preferences. Tutorial: how to create custom live template?
Why my date formatters test fails in CI and passes locally?
The story of debugging date time formatting issue. It passes locally, it fails on CI. How can it be?
Introducing stories: Quick Testing Tips
KotlinTesting.com now has stories!
Nested tests with Junit5
Nested tests in Junit5 allows us grouping test cases. Check how to do this in presenter tests.
Q & A from conferences 2020
Frequently Asked Questions – now I’m giving answers about things you’ve asked me on 2020 conferences.
Mocking and stubbing suspend functions with MockK
MockK over the years became my go-to library for mocking suspend functions. Its intuitive syntax and built-in coroutine support simplify testing asynchronous operations. With MockK, you can easily replicate complex behaviors of coroutine-based functions, ensuring tests are reflective of real-world scenarios.
Mock – fake version of an object used in testing to check how other parts of a program interact with it.
Stub – fake part of the program that always returns the same result.
This article will show you how to use both in testing Kotlin code with MockK.
Intro to testing Ktor controllers
Functional tests in Ktor – how to mock application server with TestApplicationEngine?