More fixes in checking dates in tests

This commit is contained in:
Jose Lorenzo Rodriguez 2011-10-05 12:16:00 -04:30
parent 746062d4a4
commit 16ffee0065

View file

@ -3361,13 +3361,14 @@ class ModelWriteTest extends BaseModelTest {
'author_id' => '2',
'title' => 'Creating a fourth post',
'body' => 'Fourth post body',
'published' => 'N',
'created' => $ts,
'updated' => $ts
'published' => 'N'
)));
$this->assertTrue($result[0]['Post']['updated'] >= $ts);
$this->assertTrue($result[1]['Post']['updated'] >= $ts);
$this->assertTrue($result[3]['Post']['created'] >= $ts);
$this->assertTrue($result[3]['Post']['updated'] >= $ts);
unset($result[0]['Post']['updated'], $result[1]['Post']['updated']);
unset($result[3]['Post']['created'], $result[3]['Post']['updated']);
$this->assertEqual($expected, $result);
$TestModel->validate = array('title' => 'notEmpty', 'author_id' => 'numeric');