Lines:
1 to 53 of 53
<?php // (C) Copyright Bobbing Wide 2016 /** * This file is a subset of the code from /phpunit/includes/functions.php * stripped down to what we actually need for in situ tests */ //require_once dirname( __FILE__ ) . '/class-basic-object.php'; //require_once dirname( __FILE__ ) . '/class-basic-subclass.php'; /* function tests_reset__SERVER() – Resets various `$_SERVER` variables that can get altered during tests. */ // For adding hooks before loading WP /* function tests_add_filter() – */ /* function _test_filter_build_unique_id() – */ /* function _delete_all_data() – Disabled */ /* function _delete_all_posts() – Disabled */ /* function _wp_die_handler() – */ /* function _disable_wp_die() – */ /* function _enable_wp_die() – */ /* function _wp_die_handler_filter() – */ /* function _wp_die_handler_txt() – */ /* function _set_default_permalink_structure_for_tests() – Set a permalink structure. */ /* function _upload_dir_no_subdir() – Helper used with the `upload_dir` filter to remove the /year/month sub directories from the uploads path and URL. */ /* function _upload_dir_https() – Helper used with the `upload_dir` filter to set https upload URL. */ // Skip `setcookie` calls in auth_cookie functions due to warning: // Cannot modify header information - headers already sent by ... if ( !function_exists( 'wp_set_auth_cookie' ) ) { /* function wp_set_auth_cookie() – These are pluggable functions that should have been loaded earlier We may not need them for in situ so wrapping in function_exists tests. */ } if ( !function_exists( 'wp_clear_auth_cookie' ) ) { /* function wp_clear_auth_cookie() – This action is documented in wp-inclues/pluggable.php */ }View on GitHub