gcalctool r2375 - trunk/gcalctool



Author: rancell
Date: Sun Feb 15 08:55:37 2009
New Revision: 2375
URL: http://svn.gnome.org/viewvc/gcalctool?rev=2375&view=rev

Log:
Added modulo divide and natural log tests

Modified:
   trunk/gcalctool/unittest.c

Modified: trunk/gcalctool/unittest.c
==============================================================================
--- trunk/gcalctool/unittest.c	(original)
+++ trunk/gcalctool/unittest.c	Sun Feb 15 08:55:37 2009
@@ -110,6 +110,12 @@
     test("Sqrt(4)", "2", 0);
     test("Sqrt(2)", "1.414213562", 0);
     
+    test("0 Mod 7", "0", 0);
+    test("6 Mod 7", "6", 0);
+    test("7 Mod 7", "0", 0);
+    test("8 Mod 7", "1", 0);
+    test("-1 Mod 7", "6", 0);
+    
     test("Int(3.2)", "3", 0);
     test("Frac(3.2)", "0.2", 0);
     test("Int(-3.2)", "-3", 0);
@@ -117,6 +123,8 @@
 
     test("Abs(1)", "1", 0);
     test("Abs(-1)", "1", 0);
+    
+    test("Ln(e^1)", "1", 0);
 
     test("Sin(0)", "0", 0);
     test("Sin(45) - 1/Sqrt(2)", "0", 0);
@@ -147,7 +155,6 @@
     test("Tanh(0)", "0", 0);
     test("Tanh(10) - Sinh(10)/Cosh(10)", "0", 0);
 
-
     test("Atanh(0)", "0", 0);
     test("Atanh(1/10) - 1/2*Ln(11/9)", "0", 0);
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]