junit4 icon indicating copy to clipboard operation
junit4 copied to clipboard

Problem executing remote Spock test due to java.lang.Exception failure

Open hellboy81 opened this issue 6 years ago • 3 comments

Trying to execute remote tests using JUnit 4.12 with Groovy&co steroids from IDEA:

image

 java.lang.Exception: No tests found matching method name filter from org.junit.runner.Request$1@3af039ed

 at org.junit.internal.requests.FilterRequest.getRunner(FilterRequest.java:40)
 at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
 at org.junit.runner.JUnitCore$run$0.call(Unknown Source)
 at com.onresolve.scriptrunner.canned.common.admin.RunUnitTests.doScript(RunUnitTests.groovy:320)

See also

Issue can be reproduces also by another JUnit users on this repo

hellboy81 avatar Jan 15 '19 13:01 hellboy81

IDEA is passing a Filter to JUnit to select which tests to run, but that filter filters out all tests. Three possibilities:

  1. The filter returns false when passed the Description for the test
  2. The filter returns false when passed the Description for one of the parent suites of the test.
  3. Spock uses a custom runner which has a bug in the filtering code

Either the IDEA team or the Spock team should be around to debug this.

kcooney avatar Jan 15 '19 15:01 kcooney

@hellboy81 what's com.onresolve.scriptrunner.canned.common.admin.RunUnitTests?

marcphilipp avatar Jan 15 '19 18:01 marcphilipp

@marcphilipp it's from ScriptRunner plugin for Jira.

volodymyr-havryliuk avatar Jun 21 '19 00:06 volodymyr-havryliuk