CodeExplorer assertNan example
$this->
assertTrue($objectWithBooleanProperties->boolTrue2
);
$this->
assertFalse($objectWithBooleanProperties->boolFalse2
);
// Integer Properties
$this->
assertEquals(4711,
$objectWithBooleanProperties->int1
);
$this->
assertEquals(-4711,
$objectWithBooleanProperties->int2
);
// Float Properties
$this->
assertEqualsWithDelta(123.456,
$objectWithBooleanProperties->float1, 0.01
);
$this->
assertEqualsWithDelta(-1.2344e56,
$objectWithBooleanProperties->float2, 1
);
$this->
assertEqualsWithDelta(45E-6,
$objectWithBooleanProperties->float3, 1
);
$this->
assertNan($objectWithBooleanProperties->floatNaN
);
$this->
assertInfinite($objectWithBooleanProperties->floatInf
);
$this->
assertEquals(-\INF,
$objectWithBooleanProperties->floatNegInf
);
} private function getDenormalizerForObjectWithBasicProperties() { $extractor =
$this->
createMock(PhpDocExtractor::
class);
$extractor->
method('getTypes'
) ->
will($this->
onConsecutiveCalls( [new Type('bool'
)],
[new Type('bool'
)],
[