Add test to ensure user was deleted
This commit is contained in:
parent
c55170698e
commit
62b3939aa7
|
@ -80,6 +80,10 @@ class WC_Tests_CustomerCRUD extends WC_Unit_Test_Case {
|
||||||
$customer_id = $customer->get_id();
|
$customer_id = $customer->get_id();
|
||||||
$this->assertNotEquals( 0, $customer->get_id() );
|
$this->assertNotEquals( 0, $customer->get_id() );
|
||||||
$customer->delete();
|
$customer->delete();
|
||||||
|
|
||||||
|
$user_object = get_user_by( 'id', $customer_id );
|
||||||
|
$this->assertFalse( $user_object );
|
||||||
|
|
||||||
$customer->read( $customer_id );
|
$customer->read( $customer_id );
|
||||||
$this->assertEquals( 0, $customer->get_id() );
|
$this->assertEquals( 0, $customer->get_id() );
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue