Skip to content

Catch2 floating point matchers documentation is outdated #2950

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

Open
jmonticelli opened this issue Feb 4, 2025 · 0 comments
Open

Catch2 floating point matchers documentation is outdated #2950

jmonticelli opened this issue Feb 4, 2025 · 0 comments

Comments

@jmonticelli
Copy link

Describe the bug
Looking at the documentation here it appears that the names of the matchers are missing the Matcher suffix.

Expected behavior
I would expect to be able to follow the guide 1:1 and compile successfully.

Reproduction steps
Steps to reproduce the bug.

#include <catch2/matchers/catch_matchers_floating_point.hpp>

// ...

    REQUIRE_THAT(1.0, Catch::Matchers::WithinAbs(1.2, 0.2));
// ...

Fails to compile with version 3.8.0 of Catch2.

Platform information:
Seems irrelevant for this issue

Additional context

REQUIRE_THAT(1.0, Catch::Matchers::WithinAbsMatcher(1.2, 0.2));

compiles just fine

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

No branches or pull requests

1 participant