cyjoelchen / php-sweph

PHP Extension for Swiss Ephemeris
Other
63 stars 29 forks source link

Improve Tests. #94

Closed kevindecapite closed 1 year ago

kevindecapite commented 1 year ago

Instead of rounding floats/doubles in tests with round(), this change truncates the value to x-number of decimal places for greater predictability of assertions. Accuracy testing of the SE library itself is handled in that repository; here we only care that the PHP extension is properly consuming it.

kevindecapite commented 1 year ago

@aloistr

I don't think you will want to review all these test changes; but I want to alert you to this change in the tests which now truncates the values instead of rounding them.

The change which does this is here: https://github.com/cyjoelchen/php-sweph/pull/94/files#diff-83405f55a2a7b06d88170a132d101165977a4dcff98ea3e217648d805b19539b