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

Assert::greaterThanEq and Assert::lessThanEq don't work for NAN #302

Open
johanvio opened this issue Aug 30, 2024 · 0 comments · May be fixed by #306
Open

Assert::greaterThanEq and Assert::lessThanEq don't work for NAN #302

johanvio opened this issue Aug 30, 2024 · 0 comments · May be fixed by #306
Labels

Comments

@johanvio
Copy link

Hi,

I think I just found a bug in your assertion library

$a = NAN; // not-a-number
Assert::greaterThanEq($a, 0);  // does not throw, while it should
Assert::lessThanEq($a, 0); // does not throw, while it should

eq seems to work fine with NAN:

$a = NAN;
Assert::eq($a, $a); // throws, which is fine

Thank you for your nice assertion library; I've been using it for years, and I like it very much!

@shadowhand shadowhand added the bug label Oct 15, 2024
@gordinskiy gordinskiy linked a pull request Oct 28, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants