Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A question: Is there anyway to get the count of executed scenarios and in queue scenarios at runitme ? #1922

Closed
Naumansh opened this issue Mar 20, 2020 · 5 comments
Labels
🐛 bug Defect / Bug

Comments

@Naumansh
Copy link

Question

I need to perform certain action only after last scenario has been executed in any test execution. Is there a way to get information from cucumber that how many scenarios are executed till the time or how many are left. I know we can do using a static variable but it doesnt work in parallel execution. Appreciate your help in it. Thanks.

Cucumber v : 5.4.2

@Naumansh Naumansh added the 🐛 bug Defect / Bug label Mar 20, 2020
@mpkorstanje
Copy link
Contributor

What kind of action are you thinking of? If it's reporting have a look at the TestRunFinished event. Otherwise you'll be waiting for #1876

@Naumansh
Copy link
Author

Indeed i am looking forward for 1876. I need to perform some api calls for updating tfs. So need to do it at the end of executions.

@mpkorstanje
Copy link
Contributor

I would suggest using the plugin system to generate the desired output and then have your build system interact with TFS using that output. Trying to use hooks for this will cause you more problems then its worth.

@Naumansh Naumansh reopened this Mar 22, 2020
@Naumansh
Copy link
Author

I am not sure how can i do it with plugin. I can do things after every test run or step but how can i get information that all scenarios are executed ?

@mpkorstanje
Copy link
Contributor

You can use the TestRunFinished event for that. You can find a fairly recent tutorial on a plugin that reports unused steps that you should be able to adapt to you needs.

https://blog.jdriven.com/2019/01/cucumber-jvm-plugin/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Defect / Bug
Projects
None yet
Development

No branches or pull requests

2 participants