The Trunk: CollectionsTests-cmm.195.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: CollectionsTests-cmm.195.mcz

commits-2
Chris Muller uploaded a new version of CollectionsTests to project The Trunk:
http://source.squeak.org/trunk/CollectionsTests-cmm.195.mcz

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

Name: CollectionsTests-cmm.195
Author: cmm
Time: 28 January 2013, 8:20:02.188 pm
UUID: 0f5298fb-9001-4d27-844b-3181e86da7ab
Ancestors: CollectionsTests-ul.194

Tests for FloatCollection.

=============== Diff against CollectionsTests-ul.194 ===============

Item was added:
+ ClassTestCase subclass: #FloatCollectionTest
+ instanceVariableNames: ''
+ classVariableNames: ''
+ poolDictionaries: ''
+ category: 'CollectionsTests-Sequenceable'!

Item was added:
+ ----- Method: FloatCollectionTest>>testAdd (in category 'tests') -----
+ testAdd
+ | fc |
+ fc := #(1 2 3 4 ) as: FloatCollection.
+ fc add: 88.
+ self assert: fc asArray = #(1.0 2.0 3.0 4.0 88.0 ) asFloatArray.
+ fc add: 99.
+ self assert: fc = (#(1 2 3 4 88 99 ) as: FloatCollection)!

Item was added:
+ ----- Method: FloatCollectionTest>>testInternalArray (in category 'tests') -----
+ testInternalArray
+ | fc internalArray |
+ fc := FloatCollection new.
+ self
+ deny: (internalArray := fc instVarNamed: 'array') class isPointers ;
+ assert: fc isEmpty.
+ internalArray size + 1 timesRepeat: [ fc add: 0.0 ].
+ self
+ assert: fc size = internalArray size + 1 ;
+ assert: (fc instVarNamed: 'array') size = (internalArray size * 2)!