(self)
| 590 | # Test approx_equal with NANs and INFs and zeroes. |
| 591 | |
| 592 | def test_inf(self): |
| 593 | for type_ in (float, Decimal): |
| 594 | inf = type_('inf') |
| 595 | self.assertTrue(approx_equal(inf, inf)) |
| 596 | self.assertTrue(approx_equal(inf, inf, 0, 0)) |
| 597 | self.assertTrue(approx_equal(inf, inf, 1, 0.01)) |
| 598 | self.assertTrue(approx_equal(-inf, -inf)) |
| 599 | self.assertFalse(approx_equal(inf, -inf)) |
| 600 | self.assertFalse(approx_equal(inf, 1000)) |
| 601 | |
| 602 | def test_nan(self): |
| 603 | for type_ in (float, Decimal): |
nothing calls this directly
no test coverage detected