-
- Notifications
You must be signed in to change notification settings - Fork 2.9k
Closed
Labels
good first issueeasy issue that is friendly to new contributoreasy issue that is friendly to new contributorstatus: help wanteddevelopers would like help from experts on this topicdevelopers would like help from experts on this topictopic: reportingrelated to terminal output and user-facing messages and errorsrelated to terminal output and user-facing messages and errorstype: feature-branchnew feature or API change, should be merged into features branchnew feature or API change, should be merged into features branch
Description
The new approx
function is great, but does not seem to work with inequalities, instead failing silently.
I.e.
def test_aprox_inequal(): assert pytest.approx(0.0) <= 5.0
gives
def test_aprox_inequal(): > assert pytest.approx(0.0) <= 5.0 E assert 0.0 ± 1.0e-12 <= 5.0 E + where 0.0 ± 1.0e-12 = <class '_pytest.python.approx'>(0.0) E + where <class '_pytest.python.approx'> = pytest.approx
It would be great if inequality testing was also supported with approx
, and if not then this should give a better error message.
Metadata
Metadata
Assignees
Labels
good first issueeasy issue that is friendly to new contributoreasy issue that is friendly to new contributorstatus: help wanteddevelopers would like help from experts on this topicdevelopers would like help from experts on this topictopic: reportingrelated to terminal output and user-facing messages and errorsrelated to terminal output and user-facing messages and errorstype: feature-branchnew feature or API change, should be merged into features branchnew feature or API change, should be merged into features branch