Skip to content

Commit

Permalink
Use assertArrayHasKey and assertArrayNotHasKey (#774)
Browse files Browse the repository at this point in the history
  • Loading branch information
carusogabriel authored and jdpedrie committed Dec 6, 2017
1 parent f78b8ba commit 131def5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion tests/unit/Datastore/EntityMapperTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -541,7 +541,7 @@ public function testValueExcludeFromIndexes()

$res = $this->mapper->valueObject('hello', false);

$this->assertFalse(isset($res['excludeFromIndexes']));
$this->assertArrayNotHasKey('excludeFromIndexes', $res);
}

public function testObjectPropertyBlob()
Expand Down
6 changes: 3 additions & 3 deletions tests/unit/Datastore/EntityTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,11 @@ public function testCreateEntity()

$this->assertNull($entity['doesntExist']);

$this->assertFalse(isset($entity['doesntExist']));
$this->assertTrue(isset($entity['test']));
$this->assertArrayNotHasKey('doesntExist', $entity);
$this->assertArrayHasKey('test', $entity);

unset($entity['test']);
$this->assertFalse(isset($entity['test']));
$this->assertArrayNotHasKey('test', $entity);

$entity->magicProperty = 'magic value';
$this->assertEquals('magic value', $entity->magicProperty);
Expand Down

0 comments on commit 131def5

Please sign in to comment.