Skip to content

Commit d29803c

Browse files
committed
MAGETWO-89238: [Sales email] Disabled invoice emails produce performance issue
1 parent c274bfb commit d29803c

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

dev/tests/integration/testsuite/Magento/Sales/Model/InvoiceEmailSenderHandlerTest.php

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,19 @@ public function testInvoiceEmailSenderExecute()
8585

8686
$this->assertCount($expectedResult, $sendCollection->getItems());
8787
}
88+
89+
/**
90+
* @inheritdoc
91+
* @throws \Magento\Framework\Exception\LocalizedException
92+
* @throws \Exception
93+
*/
94+
protected function tearDown()
95+
{
96+
/** @var \Magento\Config\Model\Config $defConfig */
97+
$defConfig = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()
98+
->create(\Magento\Config\Model\Config::class);
99+
$defConfig->setScope(\Magento\Framework\App\Config\ScopeConfigInterface::SCOPE_TYPE_DEFAULT);
100+
$defConfig->setDataByPath('sales_email/general/async_sending', 0);
101+
$defConfig->save();
102+
}
88103
}

0 commit comments

Comments
 (0)