junit Nested tests with Junit5 Nested tests in Junit5 allows us grouping test cases. Check how to do this in presenter tests.
conference Q & A from conferences 2020 Frequently Asked Questions - now I'm giving answers about things you've asked me on 2020 conferences.
basics Mocking and stubbing suspend functions with MockK How to easily stub or mock suspend function in Kotlin? MockK is the solution. See MockK examples for coroutines.
ktor Intro to testing Ktor controllers Functional tests in Ktor - how to mock application server with TestApplicationEngine?
basics Using Mockito in Kotlin projects Refactoring Java Mockito based test suite to Mockito-Kotlin DSL
Android Testing Retrofit calls with OkHttp MockWebServer How to test Retrofit calls? Example of testing requests executed with Retrofit and OkHttp.
Android An attempt to unit test generated DataBinding code Story of an attempt to test the code generated by DataBinding library.
time Testing time-based code with Joda Time Testing time based properties with Joda Time - hints how to write micro DSL included!
kotest Parameterized tests with Kotest Creating parameterized tests in Kotlin: data driven testing, collection inspections and generating test cases with FreeSpec.
exceptions Handling exceptions in tests: Junit & Kotest Exceptions are crucial part of some Java APIs. How to assert that exceptions was thrown? In this note you will examples of various exception assertion techniques.
basics Test execution basics: passed, failed, crashed When the test passes, when it fails and why it crashes? In this short note we will try to find the answers for those questions.
kotest Assert softly - when one assertion is not enough It's usually in our best interest to keep one assertion per test method. Yet, situation when more than one check in single test method is present may occur.
MVVM Building Unit Tests for ViewModel in TDD style In his example we will try to implement VenueDetailsViewModel in TDD style. TDD (Test Driven Development) is development technique, where developer relies on unit tests created before actual implementation.
repository KotlinUnitTesting - repository with examples This repository contains examples of basic unit tests written in Kotlin. In specific directories you can find gradle buildscript with needed dependencies and configuration, simple unit test and parameterized test.