From 274902b03a529a070b216f0284eedf0ed23a2429 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sat, 23 Apr 2016 08:15:11 +0000 Subject: [PATCH] Build/Test Tools: Reset the PHPMailer mock in `Tests_Mail::tearDown()`. Props welcher. Fixes #36609. git-svn-id: https://develop.svn.wordpress.org/trunk@37307 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/mail.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/phpunit/tests/mail.php b/tests/phpunit/tests/mail.php index 25c49c1c84..120147cfc5 100644 --- a/tests/phpunit/tests/mail.php +++ b/tests/phpunit/tests/mail.php @@ -9,6 +9,11 @@ class Tests_Mail extends WP_UnitTestCase { unset( $GLOBALS['phpmailer']->mock_sent ); } + function tearDown() { + unset( $GLOBALS['phpmailer']->mock_sent ); + parent::tearDown(); + } + /** * Send a mail with a 1000 char long line. *