Commit b0fb04ef by Carsten Brandt

fixed test break and wrong parameter

parent 0899b8d4
......@@ -667,7 +667,7 @@ abstract class BaseActiveRecord extends Model implements ActiveRecordInterface
}
}
$values = $this->getDirtyAttributes($attributes);
$values = $this->getDirtyAttributes($attrs);
if (empty($values)) {
return 0;
}
......
......@@ -867,7 +867,7 @@ trait ActiveRecordTestTrait
/* @var $customerClass \yii\db\ActiveRecordInterface */
$customerClass = $this->getCustomerClass();
/* @var $this TestCase|ActiveRecordTestTrait */
// save
/* @var $customer Customer */
$customer = $customerClass::findOne(2);
$this->assertTrue($customer instanceof $customerClass);
$this->assertEquals('user2', $customer->name);
......@@ -879,8 +879,8 @@ trait ActiveRecordTestTrait
$this->afterSave();
$this->assertEquals('user2x', $customer->name);
$this->assertFalse($customer->isNewRecord);
$this->assertFalse(static::$afterSaveNewRecord);
$this->assertFalse(static::$afterSaveInsert);
$this->assertNull(static::$afterSaveNewRecord);
$this->assertNull(static::$afterSaveInsert);
$customer2 = $customerClass::findOne(2);
$this->assertEquals('user2x', $customer2->name);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment