|
| 1 | +<?php |
| 2 | +/************************************************************************ |
| 3 | + * |
| 4 | + * Copyright 2023 Adobe |
| 5 | + * All Rights Reserved. |
| 6 | + * |
| 7 | + * NOTICE: All information contained herein is, and remains |
| 8 | + * the property of Adobe and its suppliers, if any. The intellectual |
| 9 | + * and technical concepts contained herein are proprietary to Adobe |
| 10 | + * and its suppliers and are protected by all applicable intellectual |
| 11 | + * property laws, including trade secret and copyright laws. |
| 12 | + * Dissemination of this information or reproduction of this material |
| 13 | + * is strictly forbidden unless prior written permission is obtained |
| 14 | + * from Adobe. |
| 15 | + * ************************************************************************ |
| 16 | + */ |
| 17 | +declare(strict_types=1); |
| 18 | + |
| 19 | +namespace integration\testsuite\Magento\Config\Model; |
| 20 | + |
| 21 | +use Magento\Config\Model\Config\Source\Locale\Currency; |
| 22 | +use Magento\TestFramework\Fixture\AppIsolation; |
| 23 | +use Magento\TestFramework\Fixture\DbIsolation; |
| 24 | +use Magento\TestFramework\Helper\Bootstrap; |
| 25 | +use PHPUnit\Framework\TestCase; |
| 26 | + |
| 27 | +class CurrencyTest extends TestCase |
| 28 | +{ |
| 29 | + /** |
| 30 | + * @var Currency |
| 31 | + */ |
| 32 | + private $currency; |
| 33 | + |
| 34 | + /** |
| 35 | + * @inheritdoc |
| 36 | + */ |
| 37 | + protected function setUp(): void |
| 38 | + { |
| 39 | + parent::setUp(); |
| 40 | + |
| 41 | + $this->currency = Bootstrap::getObjectManager()->get(Currency::class); |
| 42 | + } |
| 43 | + |
| 44 | + #[ |
| 45 | + DbIsolation(true), |
| 46 | + AppIsolation(true), |
| 47 | + ] |
| 48 | + public function testNicaraguanCurrenciesExistsBoth() |
| 49 | + { |
| 50 | + $options = $this->currency->toOptionArray(); |
| 51 | + $values = []; |
| 52 | + foreach ($options as $option) { |
| 53 | + $values[] = $option['value']; |
| 54 | + } |
| 55 | + $this->assertContains('NIO', $values); |
| 56 | + $this->assertContains('NIC', $values); |
| 57 | + } |
| 58 | +} |
0 commit comments