kotest / kotest-intellij-plugin

The official Kotest plugin for Intellij and Android Studio
Apache License 2.0
179 stars 25 forks source link

KMM tests can't be run from common source set if Android is the only JVM target #261

Open OSemenovBoyarka opened 1 year ago

OSemenovBoyarka commented 1 year ago

Kotest version: 5.6.2 Kotest IntelliJ plugin version: 1.3.69-IC-2022.2 Android Studio version: 2022.2.1 Patch 2

I have a KMM project with only Android and iOS targets and I'd like to use Kotest for unit tests. The issue is whenever I create a test in a commonTest sourceset - I can't run it from the editor (run and debug buttons are grey):

Screenshot 2023-06-21 at 17 16 28

If I put that same file to the androidUnitTest source set - all works good. I can run test from commandline with ./gradlew check. And I'm also able to run it by clicking Run all tests in ... package from project navigator.

Additionally is I use create test dialog on a class which is in commonMain sourceset - it creates test file in the androidUnitTest instead of commonTest.

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

OSemenovBoyarka commented 11 months ago

This is still an issue