Make NaN test more comprehensive