Fix PHPStan errors for Email editor PHP package integration test folder

MAILPOET-6318
This commit is contained in:
Oluwaseun Olorunsola
2024-11-22 16:38:13 +01:00
committed by Jan Lysý
parent a4ad960492
commit 325c4c74f4
10 changed files with 35 additions and 13 deletions

View File

@@ -29,7 +29,7 @@ class Blocks_Registry_Test extends \MailPoetTest {
*/
public function _before() {
parent::_before();
$this->registry = $this->di_container->get( Blocks_Registry::class );
$this->registry = $this->di_container->get( Blocks_Registry::class ); // @phpstan-ignore-line
}
/**

View File

@@ -134,8 +134,8 @@ class Content_Renderer_Test extends \MailPoetTest {
*/
private function getStylesValueForTag( $html, $tag ): ?string {
$html = new \WP_HTML_Tag_Processor( $html );
if ( $html->next_tag( $tag ) ) {
return $html->get_attribute( 'style' );
if ( $html->next_tag( $tag ) ) { // @phpstan-ignore-line
return $html->get_attribute( 'style' ); // @phpstan-ignore-line
}
return null;
}