1
0
mirror of synced 2025-01-18 06:21:40 +03:00
This commit is contained in:
zYne 2007-07-31 20:24:10 +00:00
parent a57226b086
commit 8002dfa3a5

View File

@ -72,5 +72,13 @@ class Doctrine_Query_Update_TestCase extends Doctrine_UnitTestCase
$this->assertEqual($q->getQuery(), "UPDATE entity SET name = 'someone' WHERE id = 5 AND (type = 0)");
}
public function testUpdateSupportsColumnReferencing()
{
$q = new Doctrine_Query();
$q->update('User u')->set('u.id', 'u.id + 1');
$this->assertEqual($q->getQuery(), "UPDATE entity SET id = id + 1 WHERE (type = 0)");
}
}
?>