-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Exit code is zero if thresholds are not met #1526
Comments
works for me ... I think you are mistaking |
Thx for the fast response. Yes, I can. So there is the base.js file which looks like the following:
And then there is the smoke.js file that imports the other js file (in my project there is also a load.js, stress.js file):
When I execute this test, the thresholds are not met, yet the exit code is 0: |
I think I found it. Idk why, but for some reason there are some extra spaces in 'Content OK ', when I remove them, everything works as expected. Sorry for the false alarm! |
The only thing I am wondering about. Would it make sense maybe to add a warning/error if a threshold id refers to something that actually does not exist? |
👍 We sort of know about this issue and some related ones: #1346, #961 The threshold handling code needs an overhaul and we intend to make one soon: #1443 but it's worth pointing out the current issue specifically, so I did it in #1443 (comment) |
Environment
Locally:
Gitlab:
Expected Behavior
According to https://k6.io/docs/using-k6/thresholds the exit code should be != 0 in case of thresholds that are not met:
Actual Behavior
Exit code is 0
Steps to Reproduce the Problem
The text was updated successfully, but these errors were encountered: