Changeset 52010 for trunk/tests/phpunit/tests/upload.php
- Timestamp:
- 11/04/2021 03:22:47 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/upload.php
r51587 r52010 8 8 public $siteurl; 9 9 10 function set_up() {10 public function set_up() { 11 11 parent::set_up(); 12 $this-> _reset_options();12 $this->reset_options(); 13 13 } 14 14 15 function _reset_options() {15 private function reset_options() { 16 16 // System defaults. 17 17 update_option( 'upload_path', 'wp-content/uploads' ); … … 20 20 } 21 21 22 function test_upload_dir_default() {22 public function test_upload_dir_default() { 23 23 // wp_upload_dir() with default parameters. 24 24 $info = wp_upload_dir(); … … 31 31 } 32 32 33 function test_upload_dir_relative() {33 public function test_upload_dir_relative() { 34 34 // wp_upload_dir() with a relative upload path that is not 'wp-content/uploads'. 35 35 update_option( 'upload_path', 'foo/bar' ); … … 46 46 * @ticket 5953 47 47 */ 48 function test_upload_dir_absolute() {48 public function test_upload_dir_absolute() { 49 49 $path = get_temp_dir() . 'wp-unit-test'; 50 50 … … 66 66 } 67 67 68 function test_upload_dir_no_yearnum() {68 public function test_upload_dir_no_yearnum() { 69 69 update_option( 'uploads_use_yearmonth_folders', 0 ); 70 70 … … 78 78 } 79 79 80 function test_upload_path_absolute() {80 public function test_upload_path_absolute() { 81 81 update_option( 'upload_url_path', 'http://' . WP_TESTS_DOMAIN . '/asdf' ); 82 82 … … 92 92 } 93 93 94 function test_upload_dir_empty() {94 public function test_upload_dir_empty() { 95 95 // Upload path setting is empty - it should default to 'wp-content/uploads'. 96 96 update_option( 'upload_path', '' );
Note: See TracChangeset
for help on using the changeset viewer.