Skip to content

Commit b52cb4e

Browse files
committed
Merge remote-tracking branch 'andrew/fixes-for-integration-tests-to-be-compatible-php-81' into ph-delivery
2 parents 452ac5b + 2fd0f9d commit b52cb4e

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

dev/tests/integration/testsuite/Magento/Framework/View/Element/TemplateTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ public function testGetObjectData()
116116

117117
public function testGetCacheKeyInfo()
118118
{
119+
$this->_block->setTemplate($this->_block->getTemplate() ?? '');
119120
$this->assertArrayHasKey('template', $this->_block->getCacheKeyInfo());
120121
}
121122
}

dev/tests/integration/testsuite/Magento/Test/Integrity/Magento/Payment/MethodsTest.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ public function testPaymentMethod($code, $methodClass)
7171
/** @var $block \Magento\Framework\View\Element\Template */
7272
$block = $blockFactory->createBlock($blockClass);
7373
$block->setArea('frontend');
74+
$block->setTemplate($block->getTemplate() ?? '');
7475
$this->assertFileExists((string)$block->getTemplateFile(), $message);
7576
if ($model->canUseInternal()) {
7677
try {
@@ -80,6 +81,7 @@ public function testPaymentMethod($code, $methodClass)
8081
\Magento\Store\Model\Store::DEFAULT_STORE_ID
8182
);
8283
$block->setArea('adminhtml');
84+
$block->setTemplate($block->getTemplate() ?? '');
8385
$this->assertFileExists((string)$block->getTemplateFile(), $message);
8486
Bootstrap::getObjectManager()->get(
8587
\Magento\Store\Model\StoreManagerInterface::class

dev/tests/integration/testsuite/Magento/Theme/Block/Html/FooterTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@ public function testGetCacheKeyInfo()
3030
$context = $objectManager->get(\Magento\Framework\App\Http\Context::class);
3131
$context->setValue(Context::CONTEXT_AUTH, false, false);
3232
$block = $objectManager->get(\Magento\Framework\View\LayoutInterface::class)
33-
->createBlock(\Magento\Theme\Block\Html\Footer::class);
33+
->createBlock(\Magento\Theme\Block\Html\Footer::class)
34+
->setTemplate('');
3435
$storeId = $objectManager->get(\Magento\Store\Model\StoreManagerInterface::class)->getStore()->getId();
3536
$this->assertEquals(
3637
['PAGE_FOOTER', $storeId, 0, $this->_theme->getId(), false, $block->getTemplateFile(), 'template' => null],

0 commit comments

Comments
 (0)