|
|
|
@ -107,6 +107,7 @@ class TimestampBehaviorTest extends TestCase
|
|
|
|
|
[new Expression("strftime('%Y')"), date('Y')], |
|
|
|
|
['2015-10-20', '2015-10-20'], |
|
|
|
|
[time(), time()], |
|
|
|
|
[[$this, 'arrayCallable'], '2015-10-20'], |
|
|
|
|
]; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -133,6 +134,11 @@ class TimestampBehaviorTest extends TestCase
|
|
|
|
|
$this->assertEquals($expected, $model->updated_at); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public function arrayCallable($event) |
|
|
|
|
{ |
|
|
|
|
return '2015-10-20'; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* @depends testNewRecord |
|
|
|
|
*/ |
|
|
|
|