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

TODO concept #802

Open
ostrolucky opened this issue Mar 24, 2018 · 1 comment
Open

TODO concept #802

ostrolucky opened this issue Mar 24, 2018 · 1 comment
Milestone

Comments

@ostrolucky
Copy link

In PHP test frameworks world, none offer interesting feature from Perl world. This feature allows to mark test as expected to fail. More in a quote from TODO: BLOCK section of Test::More Perl module, which says

Declares a block of tests you expect to fail and $why. Perhaps it's because you haven't fixed a bug or haven't finished a new feature:


With a todo block, the tests inside are expected to fail. Test::More will run the tests normally, but print out special flags indicating they are "todo". Test::Harness will interpret failures as being ok. Should anything succeed, it will report it as an unexpected success. You then know the thing you had todo is done and can remove the TODO flag.

The nice part about todo tests, as opposed to simply commenting out a block of tests, is it's like having a programmatic todo list. You know how much work is left to be done, you're aware of what bugs there are, and you'll know immediately when they're fixed.

Once a todo test starts succeeding, simply move it outside the block. When the block is empty, delete it.

In PHPUnit there is markTestIncomplete, but it's meant to be used for tests which weren't finished yet, not really comparable.

Would be nice for atoum to take this as an opportunity to be a first PHP test framework with this concept.

@Grummfy Grummfy added this to the 4.0.0 milestone Mar 24, 2018
@Grummfy
Copy link
Member

Grummfy commented Mar 24, 2018

thanks for submiting it. Not sure if it really usefull but we will speak about it for the v4.0.0

@Grummfy Grummfy modified the milestones: 4.0.0, 5.0.0 Oct 3, 2020
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

2 participants