ironcalc / IronCalc

Main engine of the IronCalc ecosystem
Apache License 2.0
60 stars 2 forks source link

Fixing failing test: `test_complex.fn_imcos` #19

Closed fosdickio closed 4 months ago

fosdickio commented 6 months ago

Summary

This test was failing locally due to what looks to be a rounding error. This fix changes the test to allow either value.

failures:

---- test::engineering::test_complex::fn_imcos stdout ----
thread 'test::engineering::test_complex::fn_imcos' panicked at base/src/test/engineering/test_complex.rs:82:5:
assertion `left == right` failed
  left: "-6.58066304055116+7.58155274274655i"
 right: "-6.58066304055116+7.58155274274654i"
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

failures:
    test::engineering::test_complex::fn_imcos

test result: FAILED. 450 passed; 1 failed; 1 ignored; 0 measured; 0 filtered out; finished in 1.15s
codecov[bot] commented 6 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 91.37%. Comparing base (1381533) to head (8769d1f). Report is 14 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #19 +/- ## ========================================== + Coverage 90.36% 91.37% +1.00% ========================================== Files 156 167 +11 Lines 27401 29484 +2083 ========================================== + Hits 24762 26941 +2179 + Misses 2639 2543 -96 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

nhatcher commented 6 months ago

Yes, I saw this. This depends on the processor architecture.

nhatcher commented 6 months ago

See also: d2bab6608bdd940d51ce520bb2a04d1f23973d60

fosdickio commented 4 months ago

@nhatcher will take over this one. Closing.