/** * Setting up the instance of WPSEO_News_Admin_Page */ public function setUp() { parent::setUp(); // Be sure eventually hook will be removed remove_action('wpseo_news_options', array($this, 'set_default_keywords')); $this->instance = new WPSEO_News_Sitemap(); }
/** * Setting up the instance of WPSEO_News_Admin_Page */ public function setUp() { parent::setUp(); $this->post_id = $this->factory->post->create(array('post_title' => 'generate rss')); // Set post as editors pick add_post_meta($this->post_id, '_yoast_wpseo_newssitemap-editors-pick', 'on'); $this->instance = new WPSEO_News_Sitemap_Editors_Pick(); }
/** * Setting up the instance of WPSEO_News_Admin_Page */ public function setUp() { parent::setUp(); // Because is a global $wpseo_admin_pages we have to fill this one with an instance of WPSEO_Admin_Pages global $wpseo_admin_pages; if (empty($wpseo_admin_pages)) { $wpseo_admin_pages = new WPSEO_Admin_Pages(); } $this->instance = new WPSEO_News_Admin_Page(); }