We have an assertWithinMargin method for these kind of situations. It might be helpful here.