elastic / apm

Elastic Application Performance Monitoring - resources and general issue tracking for Elastic APM.
https://www.elastic.co/apm
Apache License 2.0
384 stars 114 forks source link

Changing cucumber specs dir setting for sync #551

Closed eyalkoren closed 3 years ago

eyalkoren commented 3 years ago

I want to move the cucumber code to a separate package, but Cucumber searches the scripts based on the directory, so I am editing this as well

apmmachine commented 3 years ago

:green_heart: Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

#### Build stats * Start Time: 2021-11-17T14:58:59.518+0000 * Duration: 3 min 23 sec * Commit: 2be7358bbd7835834659163477599ba1d5814e78

SylvainJuge commented 3 years ago

Can you elaborate a bit on how it changes the current behavior ? As far as I remember, it relies more on classpath than actual folder location, not sure if that makes any difference here.

Also, changing the location requires to also move:

eyalkoren commented 3 years ago

As far as I remember, it relies more on classpath than actual folder location, not sure if that makes any difference here.

No, it looks in a path that matches the package, otherwise I wouldn't have done it. I believe the resources folder is added to the test classpath in its entirety.

Also, changing the location requires to also move: common step definitions in specs package

This is the reason I had to do that - I started by moving the code because it is mixed with the JSON specs, then the tests didn't find the gherkin scripts. When I have code that uses a new dependency (like cucumber), it's usually a good indication for me that at least some modularization makes sense, so a dedicated package is one option.

Anyway, let's drop that, I'll just leave everything in the original package/folder for now.