Skip to content

JUnit‐5 ‐ Setup

Devrath edited this page Oct 23, 2023 · 1 revision

github-header-image

Add the plugin in the app-level build.gradle

plugins {
    id 'de.mannodermaus.android-junit5' version "1.9.3.0"
}

Add the below code in android block of app-level build.gradle

composeOptions {
     kotlinCompilerExtensionVersion '1.4.5'
}

Add the dependencies in the app-level build.gradle

testImplementation "org.junit.jupiter:junit-jupiter-api:5.9.3"
testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:5.9.3"
testImplementation "org.junit.jupiter:junit-jupiter-params:5.9.3"