Handling feature flags in test runs #837
-
|
Hi all I'm curious to know how others are handling feature flags when running tests with Reqnroll. My initial plan is:
One of the reasons that I'm choosing this approach is that our feature flags are not especially long-lived, so having steps defined to check the flag status will mean more complicated test maintenance when a particular feature flag will retire. It is mainly the last point that I'm having problems with. I can add in Assert.Inconclusive in the BeforeScenario hook, but then all of the other steps are logged as if they errored out. It's not the end of the world, but I can forsee having to explain what has happened over and over again. I found Skipping Scenarios in the documentation, which seems exactly what I'm looking for, but that will only run in steps, not in hooks. It does make me think that people are using steps to check (or toggle) flag status though. (We won't be toggling flag status during test run, as we have a lot of parallel executions that will be impacted) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
|
I think I am doing a very similar approach to yours. The only addition I have is that I have some scenarios that need to be run for "all except flag1", so I also have tags like
Could you please elaborate on this a bit more in detail? Despite what the doc is saying (outdated?), I think this should generally work in hooks as well, at least I use it in a BeforeScenario hook in my project. |
Beta Was this translation helpful? Give feedback.
I think I am doing a very similar approach to yours. The only addition I have is that I have some scenarios that need to be run for "all except flag1", so I also have tags like
@notSupported:flag1.