8
8
9
9
namespace Magento \MediaContentCatalog \Model \ResourceModel ;
10
10
11
- use Magento \MediaContentApi \Api \GetAssetIdByContentFieldInterface ;
11
+ use Magento \MediaContentApi \Api \GetAssetIdsByContentFieldInterface ;
12
12
use Magento \Store \Model \StoreManagerInterface ;
13
13
use Magento \TestFramework \Helper \Bootstrap ;
14
14
use PHPUnit \Framework \TestCase ;
15
15
16
16
/**
17
17
* Test for GetAssetIdByContentFieldTest
18
18
*/
19
- class GetAssetIdByContentFieldTest extends TestCase
19
+ class GetAssetIdsByContentFieldTest extends TestCase
20
20
{
21
21
private const STORE_FIELD = 'store_id ' ;
22
22
private const STATUS_FIELD = 'content_status ' ;
23
23
private const STATUS_ENABLED = '1 ' ;
24
24
private const STATUS_DISABLED = '0 ' ;
25
25
26
26
/**
27
- * @var GetAssetIdByContentFieldInterface
27
+ * @var GetAssetIdsByContentFieldInterface
28
28
*/
29
- private $ getAssetIdByContentField ;
29
+ private $ getAssetIdsByContentField ;
30
30
31
31
/**
32
32
* @var int
@@ -40,7 +40,7 @@ protected function setUp(): void
40
40
{
41
41
$ objectManager = Bootstrap::getObjectManager ();
42
42
$ this ->storeId = $ objectManager ->get (StoreManagerInterface::class)->getStore ()->getId ();
43
- $ this ->getAssetIdByContentField = $ objectManager ->get (GetAssetIdByContentFieldInterface ::class);
43
+ $ this ->getAssetIdsByContentField = $ objectManager ->get (GetAssetIdsByContentFieldInterface ::class);
44
44
}
45
45
46
46
/**
@@ -53,7 +53,7 @@ public function testCategoryStoreView(): void
53
53
{
54
54
$ this ->assertEquals (
55
55
[2020 ],
56
- $ this ->getAssetIdByContentField ->execute (self ::STORE_FIELD , (string )$ this ->storeId )
56
+ $ this ->getAssetIdsByContentField ->execute (self ::STORE_FIELD , (string )$ this ->storeId )
57
57
);
58
58
}
59
59
@@ -67,7 +67,7 @@ public function testProductStoreView(): void
67
67
{
68
68
$ this ->assertEquals (
69
69
[2020 ],
70
- $ this ->getAssetIdByContentField ->execute (self ::STORE_FIELD , (string )$ this ->storeId )
70
+ $ this ->getAssetIdsByContentField ->execute (self ::STORE_FIELD , (string )$ this ->storeId )
71
71
);
72
72
}
73
73
@@ -81,7 +81,7 @@ public function testProductStatusEnabled(): void
81
81
{
82
82
$ this ->assertEquals (
83
83
[2020 ],
84
- $ this ->getAssetIdByContentField ->execute (self ::STATUS_FIELD , self ::STATUS_ENABLED )
84
+ $ this ->getAssetIdsByContentField ->execute (self ::STATUS_FIELD , self ::STATUS_ENABLED )
85
85
);
86
86
}
87
87
@@ -95,7 +95,7 @@ public function testProductStatusDisabled(): void
95
95
{
96
96
$ this ->assertEquals (
97
97
[],
98
- $ this ->getAssetIdByContentField ->execute (self ::STATUS_FIELD , self ::STATUS_DISABLED )
98
+ $ this ->getAssetIdsByContentField ->execute (self ::STATUS_FIELD , self ::STATUS_DISABLED )
99
99
);
100
100
}
101
101
}
0 commit comments