Skip to content

Commit

Permalink
adding tests for containsKey
Browse files Browse the repository at this point in the history
  • Loading branch information
pfmmfp committed Sep 2, 2024
1 parent def70e0 commit 4ddf2a6
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/unit/Collection/AbstractMapTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -555,8 +555,9 @@ public function testContains(): void
]);

static::assertTrue($map->contains('foo'));
static::assertTrue($map->containsKey('foo'));
static::assertTrue($map->contains('bar'));
static::assertFalse($map->contains('baz'));
static::assertFalse($map->containsKey('baz'));
}

public function testGet(): void
Expand Down
2 changes: 2 additions & 0 deletions tests/unit/Collection/AbstractSetTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -484,8 +484,10 @@ public function testContains(): void
]);

static::assertTrue($vector->contains('hello'));
static::assertTrue($vector->containsKey('hello'));
static::assertTrue($vector->contains('world'));
static::assertFalse($vector->contains('foo'));
static::assertFalse($vector->containsKey('foo'));
}

public function testGet(): void
Expand Down
2 changes: 2 additions & 0 deletions tests/unit/Collection/AbstractVectorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,9 @@ public function testContains(): void

static::assertTrue($vector->contains(0));
static::assertTrue($vector->contains(1));
static::assertTrue($vector->containsKey(1));
static::assertFalse($vector->contains(2));
static::assertFalse($vector->containsKey(2));
}

public function testGet(): void
Expand Down

0 comments on commit 4ddf2a6

Please sign in to comment.