https://kotlinlang.org logo
#multiplatform
Title
# multiplatform
k

Kris Wong

01/28/2020, 4:59 PM
is there a "right way" to run android unit tests when all the tests are in commonTest?
running the
test
gradle task works to some degree, but w/o any fancy IDE integration
check
works, per https://kotlinlang.org/docs/reference/building-mpp-with-gradle.html#running-tests. however, there's no
androidTest
task
b

basher

01/28/2020, 5:18 PM
testDebugUnitTest is what we do
k

Kris Wong

01/28/2020, 5:19 PM
that stopped working for me, but it did work for a while
i am assuming it was when I switched from JVM to Android
b

basher

01/28/2020, 5:20 PM
It has up-to-date checks, so it might not re-run. Try modifying test file (non whitespace change)
r

russhwolf

01/29/2020, 12:09 AM
There’s a
cleanAllTests
task you can use to force tests to rerun without needing to change anything else
🙌 2