snitch-org / snitch

Lightweight C++20 testing framework.
Boost Software License 1.0
252 stars 7 forks source link

Fix color codes used even when `--color never` is specified #148

Closed cschreib closed 7 months ago

cschreib commented 7 months ago

This PR fixes #147:

Note that, in both cases, argument ordering remains irrelevant, so --color never --help and --help --color never produces the same output.

codecov[bot] commented 7 months ago

Codecov Report

Merging #148 (fa587c0) into main (770286e) will increase coverage by 0.10%. Report is 2 commits behind head on main. The diff coverage is 72.13%.

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/snitch-org/snitch/pull/148/graphs/tree.svg?width=650&height=150&src=pr&token=X422DE81PN&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org)](https://app.codecov.io/gh/snitch-org/snitch/pull/148?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org) ```diff @@ Coverage Diff @@ ## main #148 +/- ## ========================================== + Coverage 93.67% 93.78% +0.10% ========================================== Files 27 27 Lines 1597 1624 +27 ========================================== + Hits 1496 1523 +27 Misses 101 101 ``` | [Files](https://app.codecov.io/gh/snitch-org/snitch/pull/148?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org) | Coverage Δ | | |---|---|---| | [include/snitch/snitch\_cli.hpp](https://app.codecov.io/gh/snitch-org/snitch/pull/148?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org#diff-aW5jbHVkZS9zbml0Y2gvc25pdGNoX2NsaS5ocHA=) | `100.00% <ø> (ø)` | | | [src/snitch\_registry.cpp](https://app.codecov.io/gh/snitch-org/snitch/pull/148?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org#diff-c3JjL3NuaXRjaF9yZWdpc3RyeS5jcHA=) | `94.88% <100.00%> (ø)` | | | [src/snitch\_cli.cpp](https://app.codecov.io/gh/snitch-org/snitch/pull/148?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org#diff-c3JjL3NuaXRjaF9jbGkuY3Bw) | `83.87% <71.66%> (+2.73%)` | :arrow_up: | ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/snitch-org/snitch/pull/148?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/snitch-org/snitch/pull/148?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org). Last update [770286e...fa587c0](https://app.codecov.io/gh/snitch-org/snitch/pull/148?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=snitch-org).