refactored float assert