quarkiverse / quarkus-cucumber

Quarkus Cucumber extension
Apache License 2.0
14 stars 14 forks source link

Add support for uri linking per feature and scenario #101

Open dmi3coder opened 1 year ago

dmi3coder commented 1 year ago

Currently, dynamic tests don't backlink to a location of scenario or feature. image Here I can't locate a file where this feature is defined. It makes the whole process frustrating. It locates me to the main test file that defines those tests: image

gsmet commented 1 year ago

@dmi3coder is it something that can be handled by the extension? If so a PR would be welcome.

dmi3coder commented 1 year ago

@gsmet I'm trying to hack into it. I see that DynamicTest.dynamicTest accepts URI as a second parameter, which is not passed in a plugin. If i'll get something working I'll create a PR :+1: . Based on some other projects I think that should work

dmi3coder commented 1 year ago

Yep, my theory worked by passing something like this:

Thread.currentThread().getContextClassLoader().getResource(p.getUri().getSchemeSpecificPart()).toURI()

As second parameter to DynamicTest.dynamicTest. Will dig deeper over the weekend how to point it to specific line of feature/scenario