private function installApp(): void
{ $fixturesPath = __DIR__ . '/../../../../../tests/integration/Core/Framework/App/Manifest/_fixtures';
$manifest = Manifest::
createFromXmlFile($fixturesPath . '/test/manifest.xml'
);
$this->appLifecycle->
install($manifest, false,
$this->context
);
/** @var AppEntity $app */
$app =
$this->appRepository->
search((new Criteria())->
addAssociation('scriptConditions'
),
$this->context
)->
first();
$this->appId =
$app->
getId();
$this->appStateService->
activateApp($this->appId,
$this->context
);
$conditions =
$app->
getScriptConditions();
static::
assertInstanceOf(AppScriptConditionCollection::
class,
$conditions);
$condition =
$conditions->
first();
static::
assertInstanceOf(AppScriptConditionEntity::
class,
$condition);
$this->scriptId =
$condition->
getId();
} private function createSalesChannelContext(): SalesChannelContext
{ $salesChannelContextFactory =
$this->
getContainer()->
get(SalesChannelContextFactory::
class);
return $salesChannelContextFactory->
create(Uuid::
randomHex(), TestDefaults::SALES_CHANNEL
);
}