kotest / kotest-intellij-plugin

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

"Test Framework quit unexpectedly" error running ignored test #251

Open ShindongLee opened 1 year ago

ShindongLee commented 1 year ago

Kotlin 1.8.20 Kotest 5.5.5

sc 138
@Ignored
class SampleTest: FreeSpec({
    "test" {
        println("test")
    }
})

In earlier versions, it was possible to run a specific test in Kotest by clicking the '>' button next to the test name, even if the corresponding spec was ignored. This was very useful when wanting to run a test in the IDE, but not wanting to run it every time for CI.

sc 137

However, with the current version, running a single test using the '>' button results in a "Test Framework quit unexpectedly" error. It is not clear whether this is an issue with Kotest or with its IntelliJ plugin.

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.

Tomasz-Marciniak commented 3 months ago

@ShindongLee - Intellij kotest plugin runs a single test with pure Java command. In my case the test was simply not found because I used @Tags and @RequiresTag annotation so to fix it I had to add the tag to execution configuration.

  1. Open run configuration which is failing
  2. Click modify option
  3. Add "add vm options"
  4. -Dkotest.tags="myTag"