I was doing some unit testing at work and a peculiar error popped up for one of the assertions. Note that expectedValue and actualValue are both doubles.
Ass
You could convert both to a string : actualValue.ToString("0.000") and compare those strings.
actualValue.ToString("0.000")
That could be made to match your requirements closely.