Skip to content

Releases: mannodermaus/android-junit5

Gradle Plugin 1.5.2.0

09 Oct 19:40
45a2d72
Compare
Choose a tag to compare

This release of the android-junit5 Gradle Plugin brings compatibility with JUnit 5.5.2.

Gradle Plugin 1.5.1.0

07 Aug 04:41
Compare
Choose a tag to compare

This release of the android-junit5 Gradle Plugin brings compatibility with JUnit 5.5.1.

Fixed

  • Compatibility for the latest iterations of AGP 3.6.x (#180)

Gradle Plugin 1.5.0.0

14 Jul 19:34
Compare
Choose a tag to compare

This release of the android-junit5 Gradle Plugin brings compatibility with JUnit 5.5.0.

Added

  • Integrity checks for users including instrumentation tests into their project. An error will be thrown on incomplete setup of the instrumentation test environment. To disable the check, use the junitPlatform.instrumentationTests.integrityCheckEnabled API
  • Added Gradle tasks to generate resource files for filter configurations in instrumentation tests (support @Tag filters in instrumentation tests)

Changed

  • Use Dokka for platform-agnostic generation of documentation files

Removed

  • Marked junitPlatform.instrumentationTests.enabled and junitPlatform.instrumentationTests.version as deprecated, as they don't do anything anymore - they are scheduled for removal in 1.6.0.0

Instrumentation 1.1.0

14 Jul 19:36
Compare
Choose a tag to compare

This version of the instrumentation libraries allows filtering support with @Tag for instrumentation tests! 🎉

Added

  • Added support for @Tag filtering in androidTest methods & classes; this requires using Gradle Plugin 1.5.0.0 or newer to work!

Changed

  • Replaced RunnerBuilder implementation for JUnit 5 to be less dependent on the JUnitPlatform Runner

Gradle Plugin 1.4.2.1

12 Jun 20:17
Compare
Choose a tag to compare

This version of the JUnit 5 plugin for Android fixes the compatibility with the latest versions of the Android Gradle Plugin, including the preview releases for 3.5 and 3.6.

Gradle Plugin 1.4.2.0

08 Apr 19:43
Compare
Choose a tag to compare

This release brings the compatibility to JUnit 5.4.2.

Instrumentation 1.0.0

08 Apr 19:49
Compare
Choose a tag to compare

The new instrumentation libraries are here! 🎉🎉🎉

dependencies {
  androidTestImplementation "de.mannodermaus.junit5:android-test-core:1.0.0"
  androidTestRuntimeOnly "de.mannodermaus.junit5:android-test-runner:1.0.0"
}

(More info regarding the setup can be found in the README, and shortly on the Wiki. Also, please allow some time for the new artifacts to become available on JCenter - their submission is currently pending.)

Getting to know the new libraries

The integration of JUnit 5 into Android instrumentation tests has never been easier. We introduce a new core library, and a revamped runner to execute the new tests on supported devices!

  • The best news upfront: The high minSdkVersion requirement has been removed. Of course, JUnit 5 tests will still only run on devices with supported software (i.e. Android 8.0/API 26 or higher). However, you won't need to create custom flavors to host your tests any longer. If you execute a test suite containing JUnit 5 tests on an older device, the test runner will simply ignore the new tests.

  • @ActivityTest is deprecated. With Google's push towards a unified testing API, the new JUnit 5 core library for Android tests has also migrated to the new ActivityScenario API. There is an extension which you can drop into your classes, granting access to an underlying scenario, very much like the ActivityScenarioRule would do.

  • The "old" instrumentation library is now deprecated. Please use android-test-core from now on!

Gradle Plugin 1.4.1.0

07 Apr 16:02
Compare
Choose a tag to compare

This release brings the compatibility up to JUnit 5.4.1.

Gradle Plugin: 1.3.2.0

31 Dec 08:48
Compare
Choose a tag to compare

This release brings compatibility with Gradle 5, as well as a few QOL improvements.

Added

  • Support for projects running Gradle 5.x (#131, #133)

Changed

  • Updated JUnit 5 dependencies to 5.3.2 (#132)
  • Converted all helper classes for unit tests to Kotlin & inverted the dependency between Kotlin and Groovy. Now, the only Groovy thing left in that particular module are some unit tests (#136)
  • Moved to a type-safe way to declare libraries & versions in Kotlin DSL, instead of relying on the extra API in Gradle (#137)

Fixed

  • Sample project correctly sets up its source folders (#135; thanks, @pardom!)

Removed

  • The plugin no longer tries to configure modules that use the com.android.test plugin. These modules only use instrumentation tests, and do not expose any unit test tasks. If you want JUnit 5 in these modules, use the instrumentation test libraries instead (#134)

Gradle Plugin: 1.3.1.1

04 Nov 12:24
Compare
Choose a tag to compare

This release improves the usability of the plugin for users of the Kotlin DSL for Gradle.

Added

Although not directly related to the artifact itself, the Wiki has received some love for usage with the Kotlin DSL. There are now "Getting Started" guides for both Groovy and Kotlin users.

Changed

DSL methods have been unified, so that instead of exposing two variants for Kotlin and Groovy, a single signature using Gradle's Action<T> is exposed to consumers.

If you were using Kotlin DSL with this plugin before, this can potentially be a breaking change. Because of the improved SAM interface integrations for both languages, usage of android-junit5 is now a lot cleaner in Kotlin.

1.3.1.0:

android.testOptions {
  junitPlatform {
    filters("debug", config = {
      // Configure the filter
    })
  }
}

1.3.1.1:

android.testOptions {
  junitPlatform {
    filters("debug") {
      // Configure the filter
    }
  }
}