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

Consistent way to hide ignored test cases #955

Open
Javran opened this issue Feb 14, 2021 · 3 comments
Open

Consistent way to hide ignored test cases #955

Javran opened this issue Feb 14, 2021 · 3 comments

Comments

@Javran
Copy link

Javran commented Feb 14, 2021

I noticed that there isn't a consistent way regarding how some test cases are ignored, to name a few:

I'm wondering if you are open to the idea of using some hspec facilities like configSkipPredicate from Config so those ignored cases can be uncommented but still ignored without explicitly specifying it? (This is of course assumming that all test suites are using or can be adapted to use hspec)

A potential strategy, for example, might be marking ignored tests by prefixing its description with Ignored: , and then instruct users to use stack test --ta="--skip=Ignored:" and remove --skip flag when they are up to the challenge.

@sshine
Copy link
Contributor

sshine commented Feb 26, 2021

Hi @Javran, and thanks for contributing! Sorry about the delay. Using configSkipPredicate and prefixing tests that should be skipped by default with Ignored: sounds like a very fine idea. That should mean that appending --ta="--skip=Ignored:" shouldn't be necessary, shouldn't it? Currently we cannot merge new features until we unbreak CI (#952), but you are welcome to work on this addition for the two unit test suites and we can leave it hanging until CI us unbroken.

@Javran
Copy link
Author

Javran commented Feb 26, 2021

Sorry, I was thinking about a design choice when I wrote that: the concern is if we override configSkipPredicate, student might have to either remove this override or change test case name to something not matching Ignored: in test code, in order to run ignored tests. HSpec's runner simply apply match filter and remove those skipped, meaning if we skip something by default, it might not be possible to un-skip through command line.

@asarkar
Copy link

asarkar commented Jul 17, 2022

Would #1075 help in this case?

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

No branches or pull requests

3 participants