Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 11 additions & 14 deletions tests/phpunit/tests/general/feedLinksExtra.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
/**
* Test feed_links_extra().
*
* @ticket 54713
*
* @group general
* @group template
*
Expand Down Expand Up @@ -164,12 +162,13 @@ public function set_up() {
}

/**
* @dataProvider data_feed_links_extra
* @ticket 54713
*
* @param string $title The expected title.
* @param string $type The name of the test class property containing the object ID.
* @param array $args {
* @dataProvider data_feed_links_extra
*
* @param string $title The expected title.
* @param string $type The name of the test class property containing the object ID.
* @param array $args {
* Optional arguments. Default empty.
*
* @type string $separator The separator between site name and feed type.
Expand Down Expand Up @@ -210,7 +209,7 @@ public function test_feed_links_extra( $title, $type, array $args = array() ) {
*
* @return array
*/
public function data_feed_links_extra() {
public static function data_feed_links_extra() {
return array(
'a post with a comment' => array(
'title' => 'Test Blog » Post with a comment Comments Feed',
Expand Down Expand Up @@ -400,8 +399,6 @@ public function data_feed_links_extra() {
/**
* Helper function to get the permalink based on type.
*
* @ticket 54713
*
* @param string $type The name of the test class property containing the object ID.
* @return string The permalink.
*/
Expand Down Expand Up @@ -522,10 +519,10 @@ public function test_feed_links_extra_should_output_nothing_when_show_comments_f
}

/**
* @dataProvider data_feed_links_extra_should_output_nothing_when_post_comments_feed_link_is_falsy
*
* @ticket 54703
*
* @dataProvider data_feed_links_extra_should_output_nothing_when_post_comments_feed_link_is_falsy
*
* @param string $callback The callback to use for the 'post_comments_feed_link' filter.
*/
public function test_feed_links_extra_should_output_nothing_when_post_comments_feed_link_is_falsy( $callback ) {
Expand Down Expand Up @@ -581,10 +578,10 @@ public function test_feed_links_extra_should_output_the_comments_feed_link_when_
}

/**
* @dataProvider data_feed_links_extra_should_output_nothing_when_filters_return_false
*
* @ticket 55904
*
* @dataProvider data_feed_links_extra_should_output_nothing_when_filters_return_false
*
* @param string $type The name of the test class property containing the object ID.
* @param string $filter The name of the filter to set to false.
*/
Expand All @@ -602,7 +599,7 @@ public function test_feed_links_extra_should_output_nothing_when_filters_return_
*
* @return array
*/
public function data_feed_links_extra_should_output_nothing_when_filters_return_false() {
public static function data_feed_links_extra_should_output_nothing_when_filters_return_false() {
return array(
'a post with a comment' => array(
'type' => 'post_with_comment',
Expand Down
Loading