public function testAssetConfigCacheResourceContainsDependencies() { $sourcePath =
realpath(__DIR__.'/../fixtures/dir1/file1.css'
);
$mappedAsset =
new MappedAsset('file1.css',
$sourcePath, content: 'cached content'
);
$dependentOnContentAsset =
new MappedAsset('file3.css',
realpath(__DIR__.'/../fixtures/dir2/file3.css'
));
$deeplyNestedAsset =
new MappedAsset('file4.js',
realpath(__DIR__.'/../fixtures/dir2/file4.js'
));
$dependentOnContentAsset->
addDependency(new AssetDependency($deeplyNestedAsset, isContentDependency: true
));
$mappedAsset->
addDependency(new AssetDependency($dependentOnContentAsset, isContentDependency: true
));
$notDependentOnContentAsset =
new MappedAsset( 'already-abcdefVWXYZ0123456789.digested.css',
__DIR__.'/../fixtures/dir2/already-abcdefVWXYZ0123456789.digested.css',
);
$mappedAsset->
addDependency(new AssetDependency($notDependentOnContentAsset, isContentDependency: false
));
// just adding any file as an example
$mappedAsset->
addFileDependency(__DIR__.'/../fixtures/importmap.php'
);
$mappedAsset->
addFileDependency(__DIR__.'/../fixtures/dir3'
);