Skip to content

Commit

Permalink
Test Case #454 (#455)
Browse files Browse the repository at this point in the history
  • Loading branch information
dplewis committed Jul 15, 2020
1 parent eada867 commit 07c6791
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions tests/Parse/ParseQueryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -946,6 +946,30 @@ public function testCountError()
$query->count();
}

/**
* @group query-equalTo-Zero-Count
*/
public function testEqualToCountZero()
{
Helper::clearClass('BoxedNumber');
$this->saveObjects(
5,
function ($i) {
$boxedNumber = new ParseObject('BoxedNumber');
$boxedNumber->set('Number', 0);
return $boxedNumber;
}
);
$query = new ParseQuery('BoxedNumber');
$query->equalTo('Number', 0);
$result = $query->count();
$this->assertEquals(
5,
$result,
'Did not return correct number of objects.'
);
}

public function testOrderByAscendingNumber()
{
Helper::clearClass('BoxedNumber');
Expand Down

0 comments on commit 07c6791

Please sign in to comment.