public void ToIntPtr() { var converter = ConverterFactory.Create <double, IntPtr>(); Assert.Equal(ManualConverter.DoubleToIntPtr(0d), converter(0d)); Assert.Equal(ManualConverter.DoubleToIntPtr(1d), converter(1d)); Assert.Equal(ManualConverter.DoubleToIntPtr(-1d), converter(-1d)); Assert.Equal(ManualConverter.DoubleToIntPtr(Double.MinValue), converter(Double.MinValue)); Assert.Equal(ManualConverter.DoubleToIntPtr(Double.MaxValue), converter(Double.MaxValue)); }