-
Notifications
You must be signed in to change notification settings - Fork 758
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
class library: fix issues with asPairs, asAssociations, asDict create…
…d collection size (#3101)
- Loading branch information
1 parent
6ea3780
commit f207182
Showing
3 changed files
with
25 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
TestCollection : UnitTest { | ||
|
||
test_asPairs { | ||
|
||
this.assert([2,10,100,1000].collect{ |size| size.collect{ |i| i -> i }.asPairs.size >= (size * 2) }.reduce('&&') | ||
, "asPairs on an array of associations should create an array with size higher or equal to twice the number of elements in the original array"); | ||
|
||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters