public function prepareTestData()
{
if (!empty($this->sets[static::TEST_DATA_ROLE])) {
$this->prepareData(static::TEST_DATA_ROLE);
$this->prepareRole(static::TEST_DATA_ROLE);
}
if (!empty($this->sets[static::TEST_DATA_ROLE_IMAGE])) {
$this->prepareData(static::TEST_DATA_ROLE_IMAGE);
$this->prepareRoleImage(static::TEST_DATA_ROLE_IMAGE);
}
if (!empty($this->sets[static::TEST_DATA_FARM])) {
$this->prepareFarm(static::TEST_DATA_FARM);
}
if (!empty($this->sets[static::TEST_DATA_FARM_ROLE])) {
$this->prepareData(static::TEST_DATA_FARM_ROLE);
$this->prepareFarmRole(static::TEST_DATA_FARM_ROLE);
}
if (!empty($this->sets[static::TEST_DATA_ACCOUNT_GV])) {
foreach ($this->sets[static::TEST_DATA_ACCOUNT_GV] as &$gvData) {
if (empty($gvData['accountId'])) {
$gvData['accountId'] = static::$user->getAccountId();
}
ApiTest::createEntity(new AccountGlobalVariable(), $gvData);
}
}
$this->prepareData(static::TEST_DATA);
$this->prepareData(static::TEST_DATA_PARAMS);
}