You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datasketches.apache.org by "geonove (via GitHub)" <gi...@apache.org> on 2025/05/25 12:46:04 UTC
[PR] Use REQUIRE_THROWS_WITH to check for error message [datasketches-cpp]
geonove opened a new pull request, #455:
URL: https://github.com/apache/datasketches-cpp/pull/455
I noticed that this test
```cpp
TEST_CASE("CM parameter suggestions", "[error parameters]") {
// Bucket suggestions
REQUIRE_THROWS(count_min_sketch<uint64_t>::suggest_num_buckets(-1.0), "Confidence must be between 0 and 1.0 (inclusive)." );
//...
```
was still passing even though `suggest_num_buckets` throws the following error message: `"Relative error must be at least 0."`.
This is because `REQUIRE_THROWS` doesn't check if the error message match.
`REQUIRE_THROWS_WITH` should be used instead.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org
Re: [PR] Use REQUIRE_THROWS_WITH to check for error message [datasketches-cpp]
Posted by "coveralls (via GitHub)" <gi...@apache.org>.
coveralls commented on PR #455:
URL: https://github.com/apache/datasketches-cpp/pull/455#issuecomment-2913243417
## Pull Request Test Coverage Report for [Build 15238016718](https://coveralls.io/builds/73867950)
### Details
* **0** of **0** changed or added relevant lines in **0** files are covered.
* No unchanged relevant lines lost coverage.
* Overall coverage increased (+**0.003%**) to **98.729%**
---
| Totals | [](https://coveralls.io/builds/73867950) |
| :-- | --: |
| Change from base [Build 13404673886](https://coveralls.io/builds/72308282): | 0.003% |
| Covered Lines: | 16940 |
| Relevant Lines: | 17158 |
---
##### 💛 - [Coveralls](https://coveralls.io)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org
Re: [PR] Use REQUIRE_THROWS_WITH to check for error message [datasketches-cpp]
Posted by "AlexanderSaydakov (via GitHub)" <gi...@apache.org>.
AlexanderSaydakov merged PR #455:
URL: https://github.com/apache/datasketches-cpp/pull/455
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org