Files
piratepoet/tests/integration/Config/InitializerTest.php
Jan Jakeš 6522635dc7 Exclude globals from camel case conversion
[MAILPOET-1796]
2020-01-14 15:22:42 +01:00

16 lines
553 B
PHP

<?php
namespace MailPoet\Test\Config;
class InitializerTest extends \MailPoetTest {
public function testItConfiguresHooks() {
global $wp_filter; // phpcs:ignore Squiz.NamingConventions.ValidVariableName.NotCamelCaps
$isHooked = false;
// mailpoet should hook to 'wp_loaded' with priority of 10
foreach ($wp_filter['wp_loaded'][10] as $name => $hook) { // phpcs:ignore Squiz.NamingConventions.ValidVariableName.NotCamelCaps
if (preg_match('/postInitialize/', $name)) $isHooked = true;
}
expect($isHooked)->true();
}
}