Standardized Mainsoft ConstraintCollection tests.
[mono.git] / mono / mini / basic-float.cs
index b2aff5dad302781c267df93d48bdcfa40f8feb18..7a797b03aab30fea9050ce8478f2b6f926f5655f 100644 (file)
@@ -181,9 +181,26 @@ class Tests {
                long b = (long)d;
                if (b != 1000)
                        return 0;
+               a = -1;
+               d = (double)a;
+               b = (long)d;
+               if (b != -1)
+                       return 1;
                return 4;
        }
 
+       public static int test_0_rounding () {
+               long ticks = 631502475130080000L;
+               long ticksperday = 864000000000L;
+
+               double days = (double) ticks / ticksperday;
+
+               if ((int)days != 730905)
+                       return 1;
+
+               return 0;
+       }
+
        /* FIXME: This only works on little-endian machines */
        /*
        static unsafe int test_2_negative_zero () {