Fix #11870 Correct tests expressions for Dbo VirtualFields

This commit is contained in:
Philippe Gibert 2018-03-28 13:49:45 +02:00
parent 98bc995623
commit 292dc17fc2

View file

@ -1658,7 +1658,7 @@ class DboSourceTest extends CakeTestCase {
public function testConditionKeysToStringVirtualFieldExpression() {
$Article = ClassRegistry::init('Article');
$Article->virtualFields = array(
'extra' => DboSource::expression('something virtual')
'extra' => $Article->getDataSource()->expression('something virtual')
);
$conn = $this->getMock('MockPDO', array('quote'));
$db = new DboTestSource();