Assert::thatModel(new User(['name' => 'bob']))->hasSameAttributesAs(new User(['name' => 'bob']));
public static thatModel ( |
||
$actual | ||
return |
public static function thatModel(Model $actual)
{
return ModelAssert::that($actual);
}
/** * @test */ public function shouldPassIfModelsAreEqual() { //given $product = new Product(array('name' => 'abc')); //when $otherProduct = new Product(array('name' => 'abc')); //then Assert::thatModel($product)->isEqualTo($otherProduct); }