diff --git a/tests/phpunit/tests/comment/walker.php b/tests/phpunit/tests/comment/walker.php index 443ca0c1cf..504c5e3b0f 100644 --- a/tests/phpunit/tests/comment/walker.php +++ b/tests/phpunit/tests/comment/walker.php @@ -7,6 +7,13 @@ */ class Tests_Comment_Walker extends WP_UnitTestCase { + /** + * Comment post ID. + * + * @var int + */ + private $post_id; + public function set_up() { parent::set_up(); @@ -28,7 +35,7 @@ class Tests_Comment_Walker extends WP_UnitTestCase { $comment_child = get_comment( $comment_child ); $comment_walker = new Walker_Comment(); - $comment_callback = new Comment_Callback_Test( $this, $comment_walker ); + $comment_callback = new Comment_Callback_Test_Helper( $this, $comment_walker ); wp_list_comments( array( @@ -49,7 +56,10 @@ class Tests_Comment_Walker extends WP_UnitTestCase { } } -class Comment_Callback_Test { +class Comment_Callback_Test_Helper { + private $test_walker; + private $walker; + public function __construct( Tests_Comment_Walker $test_walker, Walker_Comment $walker ) { $this->test_walker = $test_walker; $this->walker = $walker;