Would like to have the option to generate snippets in Kotlin instead of Java.
Generate snippets in Kotlin, instead of Java
Generates snippets in Java (annotation style or lamdba) only
~
~
Add Kotlin snippets
1.
2.
3.
4.
Being able to generate Kotlin snippets would simplify development.
It would also make it easier for people to get started with Cucumber in Kotlin.
(Finally, it would simplify the tutorial in the docs, but that's a sidenote ;))
N/A
This is probably best done by implementing a backend for Kotlin. This will be easier to do after I've merged develop-v5 into master.
Hi @mpkorstanje , I might be able to help on this. What exactly do you mean with 'implementing a backend for Kotlin' ?
Cucumber can be used with several JVM languages. Each language has a module responsible for discovering step definitions and creating the test context (the world). This module is called a backend.
On the develop-v5 branch you can find a really clear example of how this is supposed to work for Java 8 in the Java8Backend. The maven module also contains the code that generates the step definition interfaces and everything else.
For the current master you can find the same information in the java module but bear in mind that it hasn't been refactored yet and is burdened with several pragmatic solutions.
Thanks for that! That looks pretty straightforward. Our project uses Cucumber and Kotlin a lot, so this would be a nice feature to have. Let me get back to you on this.
@bodiam you mentioned you'd get back to me on this. Any news?
Sorry, I switched jobs, and we're not as heavily invested in cucumber as what we used to, so didn't have the time to look into this, sorry!
On 22 Sep 2019, at 22:52, M.P. Korstanje notifications@github.com wrote:
@bodiam you mentioned you'd get back to me on this. Any news?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
Cheers. No problem. Any one else feel free to pick this up if you're interested.
Continued in #1829
Most helpful comment
Thanks for that! That looks pretty straightforward. Our project uses Cucumber and Kotlin a lot, so this would be a nice feature to have. Let me get back to you on this.