codeception/verify 2.1 removed support for expect()->equals() so we need to replace it with verify()->equals(). [MAILPOET-5664]
17 lines
712 B
PHP
17 lines
712 B
PHP
<?php declare(strict_types = 1);
|
|
|
|
namespace MailPoet\Form\Block;
|
|
|
|
/**
|
|
* There is also a unit test for this class in mailpoet/tests/unit/Form/Block/BlockRendererHelperTest.php
|
|
* The integration test method that need WordPress to be loaded.
|
|
*/
|
|
class BlockRendererHelperTest extends \MailPoetTest {
|
|
public function testItEscapesKnownShortCodes() {
|
|
$text = '[mailpoet_subscribers_count] [gallery attr="attr"]inside[/gallery][unknown]';
|
|
$rendererHelper = $this->diContainer->get(BlockRendererHelper::class);
|
|
$escaped = $rendererHelper->escapeShortCodes($text);
|
|
verify($escaped)->equals('[mailpoet_subscribers_count] [gallery attr="attr"]inside[/gallery][unknown]');
|
|
}
|
|
}
|