$this->assertEquals(42, $answer);
$this->assertContains('world', 'hello world');
$this->assertArrayHasKey('foo', ['foo' => 'bar']);This will pass if the array ['foo' => 'bar'] has the key 'foo'. PHPUnit_Framework_Assert is part of the PHPUnit package library.