We will work on Apr 26th (Saturday) and will be off from Apr 30th (Wednesday) until May 2nd (Friday) for public holiday in our country

Commit 0e951b04 authored by Jonathan Day's avatar Jonathan Day

Merge remote-tracking branch 'aligent/feature/attribute_fixture_loader' into...

Merge remote-tracking branch 'aligent/feature/attribute_fixture_loader' into feature/attribute_fixture_loader

Conflicts:
	app/code/community/EcomDev/PHPUnit/Model/Mysql4/Fixture/Attribute/Abstract.php
parents 93b62fc8 9cb3055e
......@@ -160,6 +160,7 @@ abstract class EcomDev_PHPUnit_Model_Mysql4_Fixture_Attribute_Abstract
}
}
//delete entry from eav/attribute and allow FK cascade to delete all related values
//TODO: check if the attribute != is_user_defined (ie system), then *only* delete the attribute option values, not attribute definition
$this->_getWriteAdapter()
->delete(
$this->getTable('eav/attribute'),
......
......@@ -95,7 +95,11 @@ class EcomDev_PHPUnit_Model_Mysql4_Fixture_Eav_Catalog_Product extends EcomDev_P
$records = array();
$attributeCodes = $entityTypeModel->getAttributeCollection();
foreach ($row['super_attributes'] as $attributeCode) {
$attributeId = $attributeCodes->getItemByColumnValue('attribute_code',$attributeCode)->getId();
$oAttribute = $attributeCodes->getItemByColumnValue('attribute_code', $attributeCode);
if(!$oAttribute){
throw new Exception('Super attribute not found with code: ' . $attributeCode);
}
$attributeId = $oAttribute->getId();
$records[] = array(
'product_id' => $row[$this->_getEntityIdField($entityTypeModel)],
'attribute_id' => $attributeId
......
......@@ -1808,7 +1808,7 @@ abstract class EcomDev_PHPUnit_Test_Case_Controller extends EcomDev_PHPUnit_Test
array($this, 'deleteCookieCallback')
));
$this->replaceByMock('singleton', 'core/cookie', $cookie);
$this->replaceByMock('model', 'core/cookie', $cookie);
return $this;
}
......
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