Skip to content

Add support for disabling test cases. #1513

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

Closed
wants to merge 2 commits into from

Conversation

lkarsten
Copy link
Contributor

The JSON test case format has an "enabled" key that is not
currently being honored. This trivial patch adds support for skipping
test cases that has enabled set to 0.

@zimmerle zimmerle self-assigned this Jul 29, 2017
@zimmerle
Copy link
Contributor

Hi @lkarsten,

By the end of each test execution we have this summary where we show the amount of tests, and the respective results: skipped, passed, failed. Currently we just count the skipped ones if they are disabled due to a missing dependency. It would be great to have the ones disabled via JSON, to also appear in the skip summary. What do you think?

@lkarsten
Copy link
Contributor Author

Hi. I think that makes sense.

I'll look into it next week and (if successful) propose a new patch here.

@zimmerle
Copy link
Contributor

@lkarsten thank you :)

The JSON test case format has an "enabled" key that is not
currently being honored. This trivial patch adds support for skipping
test cases that has enabled set to 0.
This commit adds support for skipping test cases that have enabled=0 in
their JSON body.

A separate counter is kept and reported in the final non-automake
output, detailing disabled as a separate field.

Ref: owasp-modsecurity#1513
@lkarsten
Copy link
Contributor Author

lkarsten commented Aug 1, 2017

Hello again.

I've force-pushed a new patch now. It implements skipping the disabled ones as well as a count in the end.

Please consider this for merging into v3/master.

@lkarsten
Copy link
Contributor Author

Hello. Have you had the chance to look at this?

@zimmerle
Copy link
Contributor

Merged tahnks ;)

Just did a small fix to count the disabled test as `skip' in the test summary.

9d4ed52

@zimmerle zimmerle closed this Aug 20, 2017
zimmerle pushed a commit that referenced this pull request Aug 20, 2017
This commit adds support for skipping test cases that have enabled=0 in
their JSON body.

A separate counter is kept and reported in the final non-automake
output, detailing disabled as a separate field.

Ref: #1513
@lkarsten
Copy link
Contributor Author

Thanks :-)

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

Successfully merging this pull request may close these issues.

2 participants