Closed skys215 closed 5 years ago
Hi,
My question is: should created_at and updated_at be checked when asserting model data on tests/ApiTestTrait.php#L25?
created_at
updated_at
Can be simply skip comparing by checking the key like this:
foreach ($actualData as $key => $value) { // starts here if( $key == 'created_at' || $key == 'updated_at'){ continue; } //ends here $this->assertEquals($actualData[$key], $expectedData[$key]); }
Or maybe should removed when passing the $actualData? I'm not sure.
$actualData
Hi,
My question is: should
created_at
andupdated_at
be checked when asserting model data on tests/ApiTestTrait.php#L25?Can be simply skip comparing by checking the key like this:
Or maybe should removed when passing the
$actualData
? I'm not sure.