Changeset 53948
- Timestamp:
- 08/27/2022 12:30:08 PM (2 years ago)
- Location:
- trunk/tests/phpunit/tests
- Files:
-
- 22 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/canonical/https.php
r52010 r53948 7 7 */ 8 8 class Tests_Canonical_HTTPS extends WP_Canonical_UnitTestCase { 9 10 /** 11 * Dummy HTTP URL. 12 * 13 * @var string 14 */ 15 private $http = ''; 16 17 /** 18 * Dummy HTTPS URL. 19 * 20 * @var string 21 */ 22 private $https = ''; 23 9 24 public function set_up() { 10 25 parent::set_up(); -
trunk/tests/phpunit/tests/customize/manager.php
r53855 r53948 33 33 */ 34 34 protected static $subscriber_user_id; 35 36 /** 37 * Path to test file 1. 38 * 39 * @var string 40 */ 41 private $test_file; 42 43 /** 44 * Path to test file 2. 45 * 46 * @var string 47 */ 48 private $test_file2; 35 49 36 50 /** -
trunk/tests/phpunit/tests/feed/atom.php
r53815 r53948 14 14 public static $category; 15 15 16 private $post_count; 17 private $excerpt_only; 18 16 19 /** 17 20 * Setup a new user and attribute some posts. -
trunk/tests/phpunit/tests/feed/rss2.php
r53815 r53948 15 15 public static $post_date; 16 16 17 private $post_count; 18 private $excerpt_only; 19 17 20 /** 18 21 * Setup a new user and attribute some posts. -
trunk/tests/phpunit/tests/includes/factory.php
r52654 r53948 2 2 3 3 class TestFactoryFor extends WP_UnitTestCase { 4 5 /** 6 * @var WP_UnitTest_Factory_For_Term 7 */ 8 private $category_factory; 9 4 10 public function set_up() { 5 11 parent::set_up(); -
trunk/tests/phpunit/tests/menu/walker-nav-menu-edit.php
r52010 r53948 6 6 */ 7 7 class Tests_Menu_Walker_Nav_Menu_Edit extends WP_UnitTestCase { 8 9 /** 10 * @var \Walker_Nav_Menu_Edit 11 */ 12 private $walker; 13 8 14 protected $_wp_nav_menu_max_depth; 9 15 -
trunk/tests/phpunit/tests/menu/walker-nav-menu.php
r52248 r53948 12 12 13 13 /** 14 * Original nav menu max depth. 15 * 16 * @var int 17 */ 18 private $orig_wp_nav_menu_max_depth; 19 20 /** 14 21 * Setup. 15 22 */ … … 23 30 $this->walker = new Walker_Nav_Menu(); 24 31 25 $this-> _wp_nav_menu_max_depth = $_wp_nav_menu_max_depth;32 $this->orig_wp_nav_menu_max_depth = $_wp_nav_menu_max_depth; 26 33 } 27 34 … … 32 39 global $_wp_nav_menu_max_depth; 33 40 34 $_wp_nav_menu_max_depth = $this-> _wp_nav_menu_max_depth;41 $_wp_nav_menu_max_depth = $this->orig_wp_nav_menu_max_depth; 35 42 parent::tear_down(); 36 43 } -
trunk/tests/phpunit/tests/meta.php
r52010 r53948 6 6 class Tests_Meta extends WP_UnitTestCase { 7 7 protected $updated_mids = array(); 8 9 /** 10 * @var \WP_User 11 */ 12 private $author; 13 14 private $meta_id; 15 private $delete_meta_id; 8 16 9 17 public function set_up() { -
trunk/tests/phpunit/tests/pomo/noopTranslations.php
r52010 r53948 5 5 */ 6 6 class Tests_POMO_NOOPTranslations extends WP_UnitTestCase { 7 8 /** 9 * NOOP translations object. 10 * 11 * @var NOOP_Translations 12 */ 13 private $noop; 14 15 /** 16 * Single translation entry object. 17 * 18 * @var Translation_Entry 19 */ 20 private $entry; 21 22 /** 23 * Multi translation entries object. 24 * 25 * @var Translation_Entry 26 */ 27 private $plural_entry; 28 7 29 public function set_up() { 8 30 parent::set_up(); -
trunk/tests/phpunit/tests/post.php
r53787 r53948 10 10 protected static $grammarian_id; 11 11 12 private $post_ids = array(); 13 12 14 public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { 13 15 self::$editor_id = $factory->user->create( array( 'role' => 'editor' ) ); -
trunk/tests/phpunit/tests/privacy/wpPrivacyGeneratePersonalDataExportFile.php
r53454 r53948 46 46 47 47 /** 48 * Original error level. 49 * 50 * @var int 51 */ 52 private $orig_error_level; 53 54 /** 48 55 * Create fixtures that are shared by multiple test cases. 49 56 * … … 80 87 81 88 // Suppress warnings from "Cannot modify header information - headers already sent by". 82 $this-> _error_level = error_reporting();83 error_reporting( $this-> _error_level & ~E_WARNING );89 $this->orig_error_level = error_reporting(); 90 error_reporting( $this->orig_error_level & ~E_WARNING ); 84 91 } 85 92 … … 93 100 public function tear_down() { 94 101 $this->remove_exports_dir(); 95 error_reporting( $this-> _error_level );102 error_reporting( $this->orig_error_level ); 96 103 parent::tear_down(); 97 104 } -
trunk/tests/phpunit/tests/privacy/wpPrivacyProcessPersonalDataExportPage.php
r51568 r53948 140 140 */ 141 141 public $_export_data_grouped_fetched_within_callback; 142 143 /** 144 * Original error level. 145 * 146 * @var int 147 */ 148 private $orig_error_level; 142 149 143 150 /** … … 210 217 211 218 // Suppress warnings from "Cannot modify header information - headers already sent by". 212 $this-> _error_level = error_reporting();213 error_reporting( $this-> _error_level & ~E_WARNING );219 $this->orig_error_level = error_reporting(); 220 error_reporting( $this->orig_error_level & ~E_WARNING ); 214 221 } 215 222 … … 220 227 */ 221 228 public function tear_down() { 222 error_reporting( $this-> _error_level );229 error_reporting( $this->orig_error_level ); 223 230 224 231 parent::tear_down(); -
trunk/tests/phpunit/tests/rest-api/rest-autosaves-controller.php
r53921 r53948 25 25 protected static $child_page_id; 26 26 protected static $child_draft_page_id; 27 28 private $post_autosave; 27 29 28 30 protected function set_post_data( $args = array() ) { -
trunk/tests/phpunit/tests/rest-api/rest-controller.php
r53760 r53948 11 11 */ 12 12 class WP_Test_REST_Controller extends WP_Test_REST_TestCase { 13 14 /** 15 * @var WP_REST_Request 16 */ 17 private $request; 13 18 14 19 public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { -
trunk/tests/phpunit/tests/rest-api/rest-revisions-controller.php
r51568 r53948 16 16 protected static $editor_id; 17 17 protected static $contributor_id; 18 19 private $total_revisions; 20 private $revisions; 21 private $revision_1; 22 private $revision_id1; 23 private $revision_2; 24 private $revision_id2; 25 private $revision_3; 26 private $revision_id3; 18 27 19 28 public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { -
trunk/tests/phpunit/tests/rest-api/rest-settings-controller.php
r53921 r53948 14 14 protected static $administrator; 15 15 protected static $author; 16 17 /** 18 * @var WP_REST_Settings_Controller 19 */ 20 private $endpoint; 16 21 17 22 public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { -
trunk/tests/phpunit/tests/rest-api/rest-users-controller.php
r53936 r53948 25 25 26 26 protected static $site; 27 28 /** 29 * @var WP_REST_Users_Controller 30 */ 31 private $endpoint; 27 32 28 33 public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { -
trunk/tests/phpunit/tests/rewrite/numericSlugs.php
r52389 r53948 7 7 class Tests_Rewrite_NumericSlugs extends WP_UnitTestCase { 8 8 private $old_current_user; 9 private $author_id; 9 10 10 11 public function set_up() { -
trunk/tests/phpunit/tests/shortcode.php
r52010 r53948 7 7 protected $shortcodes = array( 'test-shortcode-tag', 'footag', 'bartag', 'baztag', 'dumptag', 'hyphen', 'hyphen-foo', 'hyphen-foo-bar', 'url', 'img' ); 8 8 9 private $atts = null; 10 private $content = null; 11 private $tagname = null; 12 13 private $filter_atts_out = null; 14 private $filter_atts_pairs = null; 15 private $filter_atts_atts = null; 16 9 17 public function set_up() { 10 18 parent::set_up(); … … 14 22 } 15 23 16 $this->atts = null; 17 $this->content = null; 18 $this->tagname = null; 19 24 $this->atts = null; 25 $this->content = null; 26 $this->tagname = null; 27 $this->filter_atts_out = null; 28 $this->filter_atts_pairs = null; 29 $this->filter_atts_atts = null; 20 30 } 21 31 -
trunk/tests/phpunit/tests/theme/customHeader.php
r53741 r53948 8 8 9 9 protected static $header_video_id; 10 11 private $customize_manager = null; 10 12 11 13 public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { -
trunk/tests/phpunit/tests/user/session.php
r52010 r53948 7 7 */ 8 8 class Tests_User_Session extends WP_UnitTestCase { 9 10 /** 11 * @var WP_User_Meta_Session_Tokens 12 */ 13 private $manager; 9 14 10 15 public function set_up() { -
trunk/tests/phpunit/tests/walker.php
r52010 r53948 9 9 class Tests_Walker extends WP_UnitTestCase { 10 10 11 /** 12 * @var Walker 13 */ 14 private $walker; 15 11 16 public function set_up() { 12 17 parent::set_up();
Note: See TracChangeset
for help on using the changeset viewer.