|
10 | 10 |
|
11 | 11 | use Magento\Framework\TestFramework\Unit\Helper\ObjectManager as ObjectManagerHelper;
|
12 | 12 | use Magento\DownloadableImportExport\Helper\Data as HelperData;
|
| 13 | +use Magento\DownloadableImportExport\Model\Import\Product\Type\Downloadable; |
13 | 14 | use PHPUnit\Framework\TestCase;
|
14 | 15 |
|
15 | 16 | class DataTest extends TestCase
|
@@ -50,15 +51,15 @@ public function isRowDownloadableEmptyOptionsDataProvider()
|
50 | 51 | return [
|
51 | 52 | 'Data set include downloadable link and sample' => [
|
52 | 53 | [
|
53 |
| - 'downloadable_links' => 'https://magento2.com/download_link', |
54 |
| - 'downloadable_samples' => 'https://magento2.com/sample_link' |
| 54 | + Downloadable::COL_DOWNLOADABLE_LINKS => 'https://magento2.com/download_link', |
| 55 | + Downloadable::COL_DOWNLOADABLE_SAMPLES => 'https://magento2.com/sample_link' |
55 | 56 | ],
|
56 | 57 | false
|
57 | 58 | ],
|
58 | 59 | 'Data set with empty' => [
|
59 | 60 | [
|
60 |
| - 'downloadable_links' => '', |
61 |
| - 'downloadable_samples' => '' |
| 61 | + Downloadable::COL_DOWNLOADABLE_LINKS => '', |
| 62 | + Downloadable::COL_DOWNLOADABLE_SAMPLES => '' |
62 | 63 | ],
|
63 | 64 | true
|
64 | 65 | ]
|
@@ -87,15 +88,15 @@ public function isRowDownloadableNoValidDataProvider()
|
87 | 88 | return [
|
88 | 89 | 'Data set include downloadable link and sample' => [
|
89 | 90 | [
|
90 |
| - 'downloadable_links' => 'https://magento2.com/download_link', |
91 |
| - 'downloadable_samples' => 'https://magento2.com/sample_link' |
| 91 | + Downloadable::COL_DOWNLOADABLE_LINKS => 'https://magento2.com/download_link', |
| 92 | + Downloadable::COL_DOWNLOADABLE_SAMPLES => 'https://magento2.com/sample_link' |
92 | 93 | ],
|
93 | 94 | true
|
94 | 95 | ],
|
95 | 96 | 'Data set with empty' => [
|
96 | 97 | [
|
97 |
| - 'downloadable_links' => '', |
98 |
| - 'downloadable_samples' => '' |
| 98 | + Downloadable::COL_DOWNLOADABLE_LINKS => '', |
| 99 | + Downloadable::COL_DOWNLOADABLE_SAMPLES => '' |
99 | 100 | ],
|
100 | 101 | false
|
101 | 102 | ]
|
@@ -267,11 +268,11 @@ public function getTypeByValueDataProvider()
|
267 | 268 | return [
|
268 | 269 | 'Case File Option Value' => [
|
269 | 270 | 'file1',
|
270 |
| - 'file' |
| 271 | + Downloadable::FILE_OPTION_VALUE |
271 | 272 | ],
|
272 | 273 | 'Case url Option Value' => [
|
273 | 274 | 'https://example.com',
|
274 |
| - 'url' |
| 275 | + Downloadable::URL_OPTION_VALUE |
275 | 276 | ]
|
276 | 277 | ];
|
277 | 278 | }
|
|
0 commit comments