From 5a33080de0e8020908a50c5f20114dceecf78825 Mon Sep 17 00:00:00 2001 From: Rachel Baker Date: Thu, 20 Oct 2016 05:24:39 +0000 Subject: [PATCH] REST API: Fix comment option leak causing another test failure. Set the 'comment_whitelist' option back to the default when tearing down wpAllowComment tests. See #38373. git-svn-id: https://develop.svn.wordpress.org/trunk@38835 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/comment/wpAllowComment.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/phpunit/tests/comment/wpAllowComment.php b/tests/phpunit/tests/comment/wpAllowComment.php index bf03d17441..44ecce6b68 100644 --- a/tests/phpunit/tests/comment/wpAllowComment.php +++ b/tests/phpunit/tests/comment/wpAllowComment.php @@ -26,6 +26,8 @@ class Tests_Comment_WpAllowComment extends WP_UnitTestCase { function tearDown() { wp_delete_post( self::$post_id, true ); wp_delete_comment( self::$comment_id, true ); + + update_option( 'comment_whitelist', 1 ); } public function test_allow_comment_if_comment_author_emails_differ() {