You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@BeforeAll in a Kotlin-based Cucumber suite did not work as expected, even though placed in a companion object and annotated @JvmStatic
β What did you expect to see?
I expected the @JvmStatic and @BeforeAll annotated method to be picked up by Cucumber without problems, as a before-all initializer method.
π¦ Which tool/library version are you using?
cucumber-java 7.20.1 kotlin 2.0.x
π¬ How could we reproduce it?
See screenhots: in Kotlin, write a suite or a test and have a beforeAll method. See the error appear.
Debug this and set a breakpoint in io.cucumber.java.MethodScanner::scan ; you'll see the beforeAll method is "seen" twice, once as a static final method (whish is OK) and once as a non-final method (in the companion object), which triggers the error.
π Any additional context?
No response
The text was updated successfully, but these errors were encountered:
π What did you see?
@BeforeAll
in a Kotlin-based Cucumber suite did not work as expected, even though placed in acompanion object
and annotated@JvmStatic
β What did you expect to see?
I expected the
@JvmStatic
and@BeforeAll
annotated method to be picked up by Cucumber without problems, as a before-all initializer method.π¦ Which tool/library version are you using?
cucumber-java 7.20.1 kotlin 2.0.x
π¬ How could we reproduce it?
See screenhots: in Kotlin, write a suite or a test and have a beforeAll method. See the error appear.
Debug this and set a breakpoint in
io.cucumber.java.MethodScanner::scan
; you'll see thebeforeAll
method is "seen" twice, once as a static final method (whish is OK) and once as a non-final method (in the companion object), which triggers the error.π Any additional context?
No response
The text was updated successfully, but these errors were encountered: