-
Notifications
You must be signed in to change notification settings - Fork 9.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🔃 [EngCom] Public Pull Requests - 2.3-develop
Accepted Public Pull Requests: - #18573: Update documentation for Order#getAppliedRuleIds (by @zack6849) - #18638: [Forwardport] Calendar icon in advance pricing alignment solved (by @speedy008) - #18608: Replace intval() function by using direct type casting to (int) (by @mage2pratik) - #18596: Fix empty cart button (by @luukschakenraad) - #18600: Fix the typo in PHPDoc comment (by @dmytro-ch) - #18571: [Forwardport] Fix Customer custom attributes lost after save (by @gelanivishal) - #18570: [Forwardport] Fix for custom product attribute changing 'backend_type' when 'is_use� (by @gelanivishal) - #18546: Backend: add missing unit test for ModuleService class (by @dmytro-ch) - #17800: Updating error message for misleading error in add product attribute code (by @aman3103) Fixed GitHub Issues: - #18581: Calendar Icon aligement Issue (reported by @jignesh26) has been fixed in #18638 by @speedy008 in 2.3-develop branch Related commits: 1. 039c88d - #18475: "Clear Shopping Cart" in Magento Blank theme no longer working after 2.2.6 (reported by @dewayneholden) has been fixed in #18596 by @luukschakenraad in 2.3-develop branch Related commits: 1. cc3835f - #18589: Empty cart button does not work (reported by @luukschakenraad) has been fixed in #18596 by @luukschakenraad in 2.3-develop branch Related commits: 1. cc3835f - #12479: Saving Customer Model directly causes loss of data (reported by @Danielc3) has been fixed in #18571 by @gelanivishal in 2.3-develop branch Related commits: 1. 2322baf 2. ce82c5c 3. 9707676 - #9219: Custom Product Attribute changes 'backend_type' when 'is_user_defined = 1' and get updated/saved in Admin Backend (reported by @mhauri) has been fixed in #18570 by @gelanivishal in 2.3-develop branch Related commits: 1. 40e128c - #17754: Misleading error in Add Product Attribute screen (reported by @milossh) has been fixed in #17800 by @aman3103 in 2.3-develop branch Related commits: 1. 9aa4cfa 2. 18e509c 3. 9a15e1f 4. 6a0485f 5. b6a899f
- Loading branch information
Showing
49 changed files
with
324 additions
and
117 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
71 changes: 71 additions & 0 deletions
71
app/code/Magento/Backend/Test/Unit/Service/V1/ModuleServiceTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
<?php | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
declare(strict_types=1); | ||
|
||
namespace Magento\Backend\Test\Unit\Service\V1; | ||
|
||
use Magento\Backend\Service\V1\ModuleService; | ||
use Magento\Framework\Module\ModuleListInterface; | ||
use Magento\Framework\TestFramework\Unit\Helper\ObjectManager; | ||
|
||
/** | ||
* Module List Service Test | ||
* | ||
* Covers \Magento\Sales\Model\ValidatorResultMerger | ||
*/ | ||
class ModuleServiceTest extends \PHPUnit\Framework\TestCase | ||
{ | ||
/** | ||
* Testable Object | ||
* | ||
* @var ModuleService | ||
*/ | ||
private $moduleService; | ||
|
||
/** | ||
* @var ModuleListInterface|\PHPUnit_Framework_MockObject_MockObject | ||
*/ | ||
private $moduleListMock; | ||
|
||
/** | ||
* Object Manager | ||
* | ||
* @var ObjectManager | ||
*/ | ||
private $objectManager; | ||
|
||
/** | ||
* Set Up | ||
* | ||
* @return void | ||
*/ | ||
protected function setUp() | ||
{ | ||
$this->moduleListMock = $this->createMock(ModuleListInterface::class); | ||
$this->objectManager = new ObjectManager($this); | ||
$this->moduleService = $this->objectManager->getObject( | ||
ModuleService::class, | ||
[ | ||
'moduleList' => $this->moduleListMock, | ||
] | ||
); | ||
} | ||
|
||
/** | ||
* Test getModules method | ||
* | ||
* @return void | ||
*/ | ||
public function testGetModules() | ||
{ | ||
$moduleNames = ['Magento_Backend', 'Magento_Catalog', 'Magento_Customer']; | ||
$this->moduleListMock->expects($this->once())->method('getNames')->willReturn($moduleNames); | ||
|
||
$expected = $moduleNames; | ||
$actual = $this->moduleService->getModules(); | ||
$this->assertEquals($expected, $actual); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.