Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
DeleteNotUsedMediaService example
private
Context
$context
;
protected
function
setUp
(
)
: void
{
Feature::
skipTestIfActive
(
'v6.6.0.0',
$this
)
;
$this
->mediaRepo =
$this
->
getContainer
(
)
->
get
(
'media.repository'
)
;
$this
->context = Context::
createDefaultContext
(
)
;
$this
->deleteMediaService =
new
DeleteNotUsedMediaService
(
$this
->mediaRepo,
$this
->
getContainer
(
)
->
get
(
'media_default_folder.repository'
)
)
;
}
public
function
testCountNotUsedMedia
(
)
: void
{
$this
->
setFixtureContext
(
$this
->context
)
;
$this
->
getTxt
(
)
;
$this
->
getPngWithoutExtension
(
)
;