From ec6de050b7992b1a74687c5524cc411b730e167c Mon Sep 17 00:00:00 2001 From: Pascal Birchler Date: Thu, 11 May 2017 19:18:53 +0000 Subject: [PATCH] Posts, Post Types: Add initial tests for `get_post_type_labels()`. See #38218. Fixes #38157. git-svn-id: https://develop.svn.wordpress.org/trunk@40635 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/post/types.php | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/tests/phpunit/tests/post/types.php b/tests/phpunit/tests/post/types.php index e7dcf84562..31a51c2020 100644 --- a/tests/phpunit/tests/post/types.php +++ b/tests/phpunit/tests/post/types.php @@ -219,27 +219,6 @@ class Tests_Post_Types extends WP_UnitTestCase { _unregister_post_type( 'foo' ); } - /** - * @ticket 33543 - */ - function test_get_post_type_labels_should_fall_back_on_defaults_when_filtered_labels_do_not_contain_the_keys() { - add_filter( 'post_type_labels_foo', array( $this, 'filter_post_type_labels' ) ); - register_post_type( 'foo' ); - - $this->assertObjectHasAttribute( 'featured_image', get_post_type_object( 'foo' )->labels ); - $this->assertObjectHasAttribute( 'set_featured_image', get_post_type_object( 'foo' )->labels ); - - _unregister_post_type( 'foo' ); - remove_filter( 'post_type_labels_foo', array( $this, 'filter_post_type_labels' ) ); - } - - public function filter_post_type_labels( $labels ) { - unset( $labels->featured_image ); - unset( $labels->set_featured_image ); - return $labels; - } - - /** * @ticket 30013 */