File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,8 @@ public function prepareTables()
4141
4242 public function testShouldInsertWithoutAlias ()
4343 {
44+ $ now = time ();
45+
4446 $ elem = new Ticket_1325_TableName_NoAlias ();
4547 $ elem ->id = 1 ;
4648 $ elem ->save ();
@@ -49,13 +51,14 @@ public function testShouldInsertWithoutAlias()
4951 ->from ('Ticket_1325_TableName_NoAlias ' )
5052 ->fetchOne (array (), Doctrine_Core::HYDRATE_ARRAY );
5153
52- $ now = time ();
5354 $ time = strtotime ($ res ['event_date ' ]);
5455 $ this ->assertTrue (($ now + 5 >= $ time ) && ($ time >= $ now ));
5556 }
5657
5758 public function testShouldInsertWithAlias ()
5859 {
60+ $ now = time ();
61+
5962 $ elem = new Ticket_1325_TableName_Aliased ();
6063 $ elem ->id = 1 ;
6164 $ elem ->save ();
@@ -64,9 +67,8 @@ public function testShouldInsertWithAlias()
6467 ->from ('Ticket_1325_TableName_Aliased ' )
6568 ->fetchOne (array (), Doctrine_Core::HYDRATE_ARRAY );
6669
67- $ now = time ();
6870 $ time = strtotime ($ res ['eventDate ' ]);
69- $ this ->assertTrue (strtotime ( $ res [ ' eventDate ' ]) > 0 );
71+ $ this ->assertTrue (( $ now + 5 >= $ time ) && ( $ time >= $ now ) );
7072 }
7173}
7274
You can’t perform that action at this time.
0 commit comments