mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Ensuring uniqueness of method cache keys, all tests passing now
This commit is contained in:
parent
08be8300ee
commit
50d4330487
2 changed files with 2 additions and 0 deletions
|
@ -2183,6 +2183,7 @@ class DboSource extends DataSource {
|
||||||
$virtualFields = $model->getVirtualField();
|
$virtualFields = $model->getVirtualField();
|
||||||
$cacheKey = array(
|
$cacheKey = array(
|
||||||
$alias,
|
$alias,
|
||||||
|
get_class($model),
|
||||||
$model->alias,
|
$model->alias,
|
||||||
$virtualFields,
|
$virtualFields,
|
||||||
$fields,
|
$fields,
|
||||||
|
|
|
@ -413,6 +413,7 @@ class ModelWriteTest extends BaseModelTest {
|
||||||
}
|
}
|
||||||
$column .= $this->db->buildColumn(array('name' => 'child_count', 'type' => 'integer'));
|
$column .= $this->db->buildColumn(array('name' => 'child_count', 'type' => 'integer'));
|
||||||
$this->db->query('ALTER TABLE '. $this->db->fullTableName('category_threads') . ' ADD ' . $column);
|
$this->db->query('ALTER TABLE '. $this->db->fullTableName('category_threads') . ' ADD ' . $column);
|
||||||
|
$this->db->flushMethodCache();
|
||||||
$Category = new CategoryThread();
|
$Category = new CategoryThread();
|
||||||
$result = $Category->updateAll(array('CategoryThread.name' => "'updated'"), array('CategoryThread.parent_id' => 5));
|
$result = $Category->updateAll(array('CategoryThread.name' => "'updated'"), array('CategoryThread.parent_id' => 5));
|
||||||
$this->assertFalse(empty($result));
|
$this->assertFalse(empty($result));
|
||||||
|
|
Loading…
Reference in a new issue