Unit Tests: Tests_Auth
needs a tearDownAfterClass
impl to avoid spillage.
See #30017, #33968. git-svn-id: https://develop.svn.wordpress.org/trunk@35175 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
5fc04e0e26
commit
9d5c7055e6
@ -32,10 +32,23 @@ class Tests_Auth extends WP_UnitTestCase {
|
||||
self::commit_transaction();
|
||||
}
|
||||
|
||||
public static function tearDownAfterClass() {
|
||||
parent::tearDownAfterClass();
|
||||
|
||||
if ( is_multisite() ) {
|
||||
wpmu_delete_user( self::$user_id );
|
||||
} else {
|
||||
wp_delete_user( self::$user_id );
|
||||
}
|
||||
|
||||
self::commit_transaction();
|
||||
}
|
||||
|
||||
function setUp() {
|
||||
parent::setUp();
|
||||
|
||||
$this->user = clone self::$_user;
|
||||
wp_set_current_user( self::$user_id );
|
||||
}
|
||||
|
||||
function test_auth_cookie_valid() {
|
||||
|
Loading…
Reference in New Issue
Block a user