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

NUnit 3.13.2 : LessThanOrEqualTo fails on a case which should succeed #3898

Closed
ydubernet opened this issue Jul 22, 2021 · 1 comment · Fixed by #3931
Closed

NUnit 3.13.2 : LessThanOrEqualTo fails on a case which should succeed #3898

ydubernet opened this issue Jul 22, 2021 · 1 comment · Fixed by #3931
Assignees
Labels
Milestone

Comments

@ydubernet
Copy link

ydubernet commented Jul 22, 2021

On latest 3.13.2 version, I have this unexpected behaviour :
image

I expect the output number to be less than or equal to the initial number, it is the case, and yet the test execution context throws an AssertionException.

Here is a code example :

[Test, Repeat(1000)]
public void Test()
{
    var floor1 = 95217168582.206969750145956m;
    var floor2 = 95217168582.20696975014595521m;
    Assert.That(floor2, Is.LessThanOrEqualTo(floor1));
}

For your interest, I have tried to reproduce it in version 3.13.1 and it does not fail.
Hence it looks linked to a bug in between 3.13.1 and 3.13.2.

Best regards

@stevenaw
Copy link
Member

Thanks for reporting this @ydubernet
I can confirm this is still present on the v3.13-dev branch

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