According to Github, the best way is to use isApproximatelyEqual(_:absoluteTolerance:) from the package swift-numerics:
#expect(someFloatingPointNumber.isApproximatelyEqual(0, absoluteTolerance: 0.001))
Topic:
Developer Tools & Services
SubTopic:
General
Tags: