ltsecurityinc安防产品在线商城代码

This commit is contained in:
2026-09-14 17:47:10 +08:00
parent 57d8444c15
commit 6a3c9c5bd8
14539 changed files with 1775310 additions and 0 deletions
@@ -0,0 +1,47 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
namespace Magento\Multishipping\Block\Checkout\Address;
use Magento\TestFramework\Helper\Bootstrap;
/**
* @magentoAppArea frontend
*/
class SelectTest extends \PHPUnit\Framework\TestCase
{
/** @var \Magento\Multishipping\Block\Checkout\Address\Select */
protected $_selectBlock;
protected function setUp(): void
{
$this->_selectBlock = Bootstrap::getObjectManager()->create(
\Magento\Multishipping\Block\Checkout\Address\Select::class
);
parent::setUp();
}
/**
* @magentoDataFixture Magento/Customer/_files/customer.php
* @magentoDataFixture Magento/Customer/_files/customer_two_addresses.php
*/
public function testGetAddressAsHtml()
{
/** @var \Magento\Customer\Api\AddressRepositoryInterface $addressRepository */
$addressRepository = Bootstrap::getObjectManager()->create(
\Magento\Customer\Api\AddressRepositoryInterface::class
);
$fixtureAddressId = 1;
$address = $addressRepository->getById($fixtureAddressId);
$addressAsHtml = $this->_selectBlock->getAddressAsHtml($address);
$this->assertEquals(
"John Smith<br />CompanyName<br />Green str, 67<br />CityM, Alabama, 75477"
. "<br />United States<br />T: <a href=\"tel:3468676\">3468676</a>",
str_replace("\n", '', $addressAsHtml),
"Address was represented as HTML incorrectly"
);
}
}