Files

11 lines
349 B
PHP
Raw Permalink Normal View History

2026-11-18 15:51:55 +01:00
<?php
/** Isolated staging fixture for the HTTP integration test. */
if (!defined('ABSPATH')) exit;
if (wp_get_environment_type() !== 'staging') return;
define('HGR_TEST_MAIL_BLOCKED', true);
add_filter('pre_wp_mail', '__return_true', PHP_INT_MAX);
add_action('send_headers', static function (): void {
header('X-HGR-Test-Mail: blocked');
});