mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-23 00:41:02 +00:00
Fix test for sum() aggregate: It was calling the count operator on
the array instead of actually summing up the values. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@39851 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
209146a7a4
commit
cb6b795926
1 changed files with 3 additions and 3 deletions
|
@ -231,11 +231,11 @@ int main()
|
|||
|
||||
a = [NSArray arrayWithObjects:
|
||||
[NSDictionary dictionaryWithObjectsAndKeys:
|
||||
[NSNumber numberWithInt: 1], @"count", nil],
|
||||
[NSNumber numberWithInt: 1], @"a", nil],
|
||||
[NSDictionary dictionaryWithObjectsAndKeys:
|
||||
[NSNumber numberWithInt: 1], @"count", nil],
|
||||
[NSNumber numberWithInt: 2], @"a", nil],
|
||||
nil];
|
||||
p = [NSPredicate predicateWithFormat: @"sum(count) == 2"];
|
||||
p = [NSPredicate predicateWithFormat: @"sum(a) == 3"];
|
||||
PASS([p evaluateWithObject: a], "aggregate sum works");
|
||||
|
||||
END_SET("basic")
|
||||
|
|
Loading…
Reference in a new issue