1

Closed

BePositive() does not work for float and double

description

This throws a exceptinon:
        double f = 3.8f;
        f.Should().BePositive();
I looked at the code and the Subject.CompareTo(0) > 0 does not work with float and double.

And the comment is wrong. As it is implemented now, 0 is not validated as positive value but the comments says 0 or greater.
Closed Aug 25, 2012 at 2:19 PM by
All done with the public beta of Fluent Assertions 2.0

comments

wrote Mar 28, 2012 at 7:38 PM

Resolved with changeset 75220.

wrote Mar 28, 2012 at 7:41 PM

Associated with changeset 75221.

dennisdoomen wrote Mar 28, 2012 at 7:43 PM

** Closed by dennisdoomen 3/28/2012 12:38 PM

dennisdoomen wrote Mar 28, 2012 at 7:43 PM

Should be on Fixed, not Closed

wrote Mar 28, 2012 at 7:44 PM

Associated with changeset 75224.

dennisdoomen wrote Mar 28, 2012 at 7:45 PM

Fixed on 1.7.1.1 and the trunk.

TSchissler wrote Apr 4, 2012 at 5:38 PM

It works, but cann you update the XML comments so in intellisense it shows correctly that it validates for greater than 0 and not >= 0