mirror of
https://github.com/codeigniter4/CodeIgniter4.git
synced 2025-02-20 11:44:28 +08:00
refactor: re-run rector
This commit is contained in:
parent
1955a33b99
commit
65b71e963b
@ -1292,7 +1292,7 @@ final class ForgeTest extends CIUnitTestCase
|
||||
$this->forge->dropKey('forge_test_1', $index, false);
|
||||
$this->forge->dropKey('forge_test_1', $uniqueIndex, false);
|
||||
|
||||
$this->assertCount(0, $this->db->getIndexData('forge_test_1'));
|
||||
$this->assertEmpty($this->db->getIndexData('forge_test_1'));
|
||||
|
||||
$this->forge->dropTable('forge_test_1', true);
|
||||
}
|
||||
@ -1500,7 +1500,7 @@ final class ForgeTest extends CIUnitTestCase
|
||||
$this->assertFalse($this->db->tableExists('dropTest'));
|
||||
|
||||
if ($this->db->DBDriver === 'SQLite3') {
|
||||
$this->assertCount(0, $this->db->getIndexData('droptest'));
|
||||
$this->assertEmpty($this->db->getIndexData('droptest'));
|
||||
}
|
||||
}
|
||||
|
||||
@ -1668,7 +1668,7 @@ final class ForgeTest extends CIUnitTestCase
|
||||
|
||||
$indexes = $this->db->getIndexData('forge_test_users');
|
||||
|
||||
$this->assertCount(0, $indexes);
|
||||
$this->assertEmpty($indexes);
|
||||
|
||||
$this->forge->dropTable('forge_test_users', true);
|
||||
}
|
||||
|
@ -58,7 +58,7 @@ final class GetTest extends CIUnitTestCase
|
||||
|
||||
$jobs = $this->db->table('job')->limit(0)->get()->getResult();
|
||||
|
||||
$this->assertCount(0, $jobs);
|
||||
$this->assertEmpty($jobs);
|
||||
}
|
||||
|
||||
public function testGetWithLimitZeroAsAll(): void
|
||||
|
@ -103,7 +103,7 @@ final class LoggerTest extends CIUnitTestCase
|
||||
|
||||
$logs = TestHandler::getLogs();
|
||||
|
||||
$this->assertCount(0, $logs);
|
||||
$this->assertEmpty($logs);
|
||||
}
|
||||
|
||||
public function testLogInterpolatesMessage(): void
|
||||
|
@ -130,7 +130,7 @@ final class FindModelTest extends LiveModelTestCase
|
||||
|
||||
// Binds should be reset to 0 after each one
|
||||
$binds = $this->model->builder()->getBinds();
|
||||
$this->assertCount(0, $binds);
|
||||
$this->assertEmpty($binds);
|
||||
|
||||
$query = $this->model->getLastQuery();
|
||||
$this->assertCount(1, $this->getPrivateProperty($query, 'binds'));
|
||||
|
@ -250,7 +250,7 @@ final class ViewTest extends CIUnitTestCase
|
||||
{
|
||||
// Make sure debugging is on for our view
|
||||
$view = new View($this->config, $this->viewsDir, $this->loader, true);
|
||||
$this->assertCount(0, $view->getPerformanceData());
|
||||
$this->assertEmpty($view->getPerformanceData());
|
||||
|
||||
$view->setVar('testString', 'Hello World');
|
||||
$expected = '<h1>Hello World</h1>';
|
||||
@ -262,12 +262,12 @@ final class ViewTest extends CIUnitTestCase
|
||||
{
|
||||
// Make sure debugging is on for our view
|
||||
$view = new View($this->config, $this->viewsDir, $this->loader, false);
|
||||
$this->assertCount(0, $view->getPerformanceData());
|
||||
$this->assertEmpty($view->getPerformanceData());
|
||||
|
||||
$view->setVar('testString', 'Hello World');
|
||||
$expected = '<h1>Hello World</h1>';
|
||||
$this->assertSame($expected, $view->renderString('<h1><?= $testString ?></h1>', [], true));
|
||||
$this->assertCount(0, $view->getPerformanceData());
|
||||
$this->assertEmpty($view->getPerformanceData());
|
||||
}
|
||||
|
||||
public function testRenderLayoutExtendsCorrectly(): void
|
||||
|
Loading…
x
Reference in New Issue
Block a user