Skip to content

Releases: mockito/mockito-kotlin

1.3.0

01 Apr 17:37
Compare
Choose a tag to compare
  • Updates Mockito to 2.7.5
  • Adds doAnswer to OngoingStubbing ( #152 )

1.2.0

01 Apr 17:37
Compare
Choose a tag to compare
  • Updates Mockito to 2.6.5
  • Introduces an enhanced settings API ( #149 ); see #148.

1.1.0

27 Dec 19:18
Compare
Choose a tag to compare
  • Updates Mockito to 2.4.5
  • Updates Kotlin to 1.0.6
  • Adds argWhere ( #141 )
  • Adds BDDMockito functions ( #142 )

1.0.1

12 Dec 18:55
Compare
Choose a tag to compare
  • Properly handles null values in argument matchers ( #133 )
  • Throws a descriptive error when null is passed to the check function ( #134 )

1.0.0

06 Dec 12:35
Compare
Choose a tag to compare

This is the first major release for Mockito-Kotlin.

What is Mockito-Kotlin?

Mockito-Kotlin is a wrapper library around Mockito.

It provides top-level functions to allow for a more idiomatic approach while using Mockito in Kotlin.
Furthermore, Mockito returns null values for calls to method like any(), which can cause NullPointerExceptions when passing them to non-nullable parameters. This library solves that issue by trying to create actual instances to return.

Mockito-Kotlin does not intend to alter any of the functionality that Mockito provides, except in places where crucial for working with Kotlin.

See the Wiki to find out how to work with Mockito-Kotlin.

1.0.0-RC1

06 Dec 12:39
Compare
Choose a tag to compare

This is the first and possibly only release candidate for Mockito-Kotlin 1.0.0.

Changes in this version:

  • Removes any deprecated methods.

0.12.0

06 Dec 12:39
Compare
Choose a tag to compare
  • isA() returns a non-null instance

0.12.1

06 Dec 12:38
Compare
Choose a tag to compare
  • Updates Kotlin to 1.0.5-2
  • Updates Mockito to 2.2.17
  • inOrder accepts a lambda for easy verification (#122)

0.12.0

06 Dec 12:38
Compare
Choose a tag to compare
  • Updates Kotlin to 1.0.5
  • Updates Mockito to 2.2.15
  • eq() returns passed value, and accepts nullable values (#117)
  • Uses null as T as default return type, with the create instance mechanism as a fallback.

0.11.0

06 Dec 12:38
Compare
Choose a tag to compare
  • More convenient API for stubbing nullable types
  • Adds a fallback to the constructors when mocking a class fails