CleanCut / green

Green is a clean, colorful, fast python test runner.
MIT License
792 stars 75 forks source link

Added --name-pattern option #46

Closed hindman closed 9 years ago

hindman commented 9 years ago
coveralls commented 9 years ago

Coverage Status

Coverage decreased (-1.56%) to 98.44% when pulling 0180e52fdfe5801e0502888cfd815ad66923cc8b on hindman:test-pattern into 3c224c48664c38abf16e64557195a0e0167d7d83 on CleanCut:master.

coveralls commented 9 years ago

Coverage Status

Coverage decreased (-1.56%) to 98.44% when pulling 0180e52fdfe5801e0502888cfd815ad66923cc8b on hindman:test-pattern into 3c224c48664c38abf16e64557195a0e0167d7d83 on CleanCut:master.

CleanCut commented 9 years ago

I like it! We've wanted this since #22! I do think we should change the name of the option to be less vague. Everything has a name, so it's not obvious from the long option --name-pattern whose name is being talked about.

What about...

-n / --test-pattern (ya, all the good short options are taken)

to indicate that the pattern is to match individual tests. We could then rename the just-introduced -p / --pattern option to

`-p / --file-pattern`

so that it is 1) also not vague and 2) matches the long name form of this new option. Then future pattern support could be introduced as --whatever-pattern with some random short option. I'm afraid the days of the short options matching the first letter of the long options is largely over for green :-(

hindman commented 9 years ago

@CleanCut The adjustments to the option naming sound very good to me. I'll make those changes and try to write some unit tests, etc.

CleanCut commented 9 years ago

Great, thanks!

hindman commented 9 years ago

@CleanCut I added some units tests and renamed the options as we discussed. For some reason, the pull request does not appear to be picking up the additional commits. Maybe there a delay in GitHub for such changes to propagate(?). Anyway, let me know if you don't see the additional commits to my test-pattern branch.

CleanCut commented 9 years ago

@hindman If I browse to your fork, I can see your additional commits, but they're not included in this pull request for some reason. Is there something you need to do to get the pull request to include the additional commits?

hindman commented 9 years ago

Not sure what the problem is. I'll close this request and start a fresh one.