[MGNLTEST-324] Support cucumber tags @staging-only @prod-only Created: 21/Oct/22  Updated: 16/Nov/22  Resolved: 26/Oct/22

Status: Closed
Project: Magnolia Test Framework
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Neutral
Reporter: Christoph Meier Assignee: Christoph Meier
Resolution: Resolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: 1d 0.5h
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoR:
Empty
Epic Link: cucumber-and-selenide-support-by-test-fwk

 Description   

Goal

Cucumber Tags can be used to filter scenarios to run / not-run depending on ENV, staging or prod.

Ideas

Instead of @staging , @prod
we could do @staging-only , @prod-only

Developer notes

Currently we use src/test/resources/junit-platform.properties
-> this works

This (in pom) did not work.
We may try again in pom file - then e.g. having 2 different profiles to run the tests.

Would be nice to pass via -Doption or ENV param in Jenksinfile

sources



 Comments   
Comment by Christoph Meier [ 24/Oct/22 ]

As far as I understand JUnit5 docu - we can mix usage of both

And: Configuration parameters supplied via system properties
take precedence over those supplied via the configuration file - see https://junit.org/junit5/docs/current/user-guide/.

And local tests show that this works fine.

SO ... that ticket is actually just research - no need to add/change code im saas-test-framework,
but adding info to the configuration file.

For cucumber specific configuration properties, please see https://github.com/cucumber/cucumber-jvm/tree/main/cucumber-junit-platform-engine#configuration-options 

 

 

Comment by Christoph Meier [ 24/Oct/22 ]

Note that the related commit to this ticket is not really changing code. (For the details check the commit).
This was more a research ticket, checking whether things work as expected/hoped.

Generated at Mon Feb 12 07:47:45 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.