mirror of
https://github.com/e107inc/e107.git
synced 2025-01-17 20:58:30 +01:00
Don't assume an empty table in e_db_abstractTest::testIsEmpty()
This commit is contained in:
parent
99aa39a8e5
commit
c68604b971
@ -851,11 +851,17 @@ abstract class e_db_abstractTest extends \Codeception\Test\Unit
|
||||
|
||||
public function testIsEmpty()
|
||||
{
|
||||
$result = $this->db->isEmpty('plugin');
|
||||
$this->db->copyTable('user', 'test_is_empty', true, true);
|
||||
|
||||
$result = $this->db->isEmpty('test_is_empty');
|
||||
$this->assertFalse($result);
|
||||
|
||||
// $result = $this->db->isEmpty('comments');
|
||||
// $this->assertTrue($result);
|
||||
$this->db->truncate('test_is_empty');
|
||||
|
||||
$result = $this->db->isEmpty('test_is_empty');
|
||||
$this->assertTrue($result);
|
||||
|
||||
$this->db->dropTable('test_is_empty');
|
||||
|
||||
$result = $this->db->isEmpty();
|
||||
$this->assertFalse($result);
|
||||
|
Loading…
x
Reference in New Issue
Block a user