Is it possible to access which tags the current scenario is tagged with within the Before hook? I know this is possible with Cucumber, but can't find a way to do it with your preprocessor. The reason I would need this is because I would like to do some conditional testing depending on which tag the scenario is tagged with.
Thanks in advance! :)
I'm looking for same case
I use it with cucumber:
Before(async function (scenario) {
const tags = scenario.pickle.tags.map(tag => tag.name);
});
Does
window.testState.currentScenario.tags give you what you want? This should work from a cucumber Before hook
Does
window.testState.currentScenario.tagsgive you what you want? This should work from a cucumber Before hook
Thanks, that's exactly what I was looking for 馃榾
Most helpful comment
Does
window.testState.currentScenario.tagsgive you what you want? This should work from a cucumber Before hook