/** * Constructor. */ protected function __construct() { parent::__construct('3.6', 'text-hover', 'c2c', __FILE__, array()); register_activation_hook(__FILE__, array(__CLASS__, 'activation')); return self::$instance = $this; }
function test_hover_applies_to_custom_filter_via_filter() { $this->assertEquals('coffee2code', apply_filters('custom_filter', 'coffee2code')); add_filter('c2c_text_hover_filters', array($this, 'add_custom_filter')); c2c_TextHover::get_instance()->register_filters(); // Plugins would typically register their filter before this originally fires $this->assertEquals($this->expected_text('coffee2code'), apply_filters('custom_filter', 'coffee2code')); }