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
Cucumber v5 error in steps file from supporting file results in "Unknown error" (no stack trace) #4314
Comments
So, there is a log in allure reporter? Error like that are not printed out to console, this is an expected behavior. Regarding that error is called unknown error, it is known issue and is fixed in #4288 |
@mgrybyk So I am a little confused by your response. Are you saying that "Unknown error" will no longer be output to the console due to fixes from #4288? So will the actual stack trace then be printed to the console? I don't understand your statement that it is an expected behavior that the stack trace would not be printed to the console. In v4 the stack trace was always printed to the console, no matter where the error occurred. It is not reasonable (IMO) to expect the dev to always have to refer to the output of a reporter service (which is an add-on) to view stack trace and see why and where there was an error in their code. Additionally, allure reporter (in this instance) names their reports with what appears to be a rather random string (perhaps it is the session id), and it is hard to figure out which report is specifically associated with any given test run to pin down the stack trace that is relevant. |
@pyxis828 Stack traces are not printed out like this because of mess in console. Logs are stored in files and are printed out by reporters |
Closing this one as it refers to expected behavior and issue that gonna be fixed with another PR soon. If you like, you make rise a feature request for printing stack traces |
[//]: # NOTE: This repository only maintains packages that are listed in the Readme. Please make sure that your issue is directly caused by one of these packages and if not file an issue in the correct 3rd party package repository.
Environment (please complete the following information):
Config of WebdriverIO
Describe the bug
When running a test, if there is a failure is a step that occurs in a file that is required by the steps file (but not in the steps file itself), there is no stack trace or other real failure returned to the console or error logs. The only error message is "Unknown error" -->
To Reproduce
Feature File
Steps File
Create the page and World files to support the above steps, but make an error in the code somewhere on one of those pages (like forget to import assert for the then step, or make an error in the getPage, camelizeString, etc. functions). In the console, the only error that you get back will be "Unknown error"
Expected behavior
When there is a failure, I expect to get a stack trace with an error message stating what the error in the code was that caused the code to fail, with some file(s) and line number(s) indicating where in the code the failure occurred.
Log
from allure reporter -->
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: