[Pkg] The Trunk: KernelTests-nice.237.mcz

commits at source.squeak.org commits at source.squeak.org
Tue Dec 11 18:58:35 UTC 2012


Nicolas Cellier uploaded a new version of KernelTests to project The Trunk:
http://source.squeak.org/trunk/KernelTests-nice.237.mcz

==================== Summary ====================

Name: KernelTests-nice.237
Author: nice
Time: 11 December 2012, 7:58:11.661 pm
UUID: 77a9df8b-65c6-8740-adaf-cfa80d1140fe
Ancestors: KernelTests-cmm.236

Test that floorLog: avoid Float overflow/underflow

=============== Diff against KernelTests-cmm.236 ===============

Item was added:
+ ----- Method: FractionTest>>testFloorLog (in category 'tests - mathematical functions') -----
+ testFloorLog
+ 	self assert: (1/100 floorLog: 10) = -2.
+ 	self assert: (((2 raisedTo: Float emax + 11)/3) floorLog: 10)
+ 		= ((Float emax + 11)*2 log - 3 log) floor description: 'Fraction>>log should not overflow'.
+ 	self assert: ((3/(2 raisedTo: Float precision - Float emin)) floorLog: 10)
+ 		= ((Float emin - Float precision)*2 log + 3 log) floor description: 'Fraction>>log should not underflow'!

Item was added:
+ ----- Method: IntegerTest>>testFloorLog (in category 'tests - mathematical functions') -----
+ testFloorLog
+ 	self assert: (100 floorLog: 10) = 2.
+ 	self assert: (((2 raisedTo: Float emax + 3) floorLog: 10) = (2 log*(Float emax + 3)) floor) description: 'Integer>>floorLog: should not overflow'!



More information about the Packages mailing list