--- a/RegressionTests__IntegerTest.st Tue Apr 27 00:02:50 2010 +0200
+++ b/RegressionTests__IntegerTest.st Tue Apr 27 10:47:55 2010 +0200
@@ -1080,7 +1080,22 @@
"
"Created: / 24-04-2010 / 13:52:23 / cg"
- "Modified: / 25-04-2010 / 21:24:19 / cg"
+ "Modified: / 27-04-2010 / 10:34:22 / cg"
+!
+
+testGCD
+ "/ <testedMethods: #( (Integer >> #gcd:) ) >
+
+ self assert:(9 gcd:6) = 3.
+ self assert:(6 gcd:9) = 3.
+ self assert:(2 gcd:0) = 2.
+ self assert:(0 gcd:2) = 2.
+
+ "
+ self basicNew testGCD
+ "
+
+ "Created: / 27-04-2010 / 09:49:31 / cg"
!
testILC
@@ -1548,6 +1563,19 @@
"
!
+testIsPowerOfTwo
+ self assert:(1 isPowerOfTwo).
+ self assert:(2 isPowerOfTwo).
+ self assert:(4 isPowerOfTwo).
+ self assert:(3 isPowerOfTwo not).
+
+ "
+ self basicNew testIsPowerOfTwo
+ "
+
+ "Created: / 27-04-2010 / 10:35:36 / cg"
+!
+
testLargeAddition
"general conversion & arithmetic tests.
Notice, the arithmetic tests are both performed via regular sends