Skip to content

Commit c0a495b

Browse files
committed
test: add return void to sample test code in appstarter
1 parent 4dfc0ef commit c0a495b

File tree

5 files changed

+8
-8
lines changed

5 files changed

+8
-8
lines changed

admin/starter/tests/_support/Database/Migrations/2020-02-22-222222_example_migration.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ class ExampleMigration extends Migration
88
{
99
protected $DBGroup = 'tests';
1010

11-
public function up()
11+
public function up(): void
1212
{
1313
$this->forge->addField('id');
1414
$this->forge->addField([
@@ -30,7 +30,7 @@ public function up()
3030
$this->forge->createTable('factories');
3131
}
3232

33-
public function down()
33+
public function down(): void
3434
{
3535
$this->forge->dropTable('factories');
3636
}

admin/starter/tests/_support/Database/Seeds/ExampleSeeder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
class ExampleSeeder extends Seeder
88
{
9-
public function run()
9+
public function run(): void
1010
{
1111
$factories = [
1212
[

admin/starter/tests/database/ExampleDatabaseTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ final class ExampleDatabaseTest extends CIUnitTestCase
1414

1515
protected $seed = ExampleSeeder::class;
1616

17-
public function testModelFindAll()
17+
public function testModelFindAll(): void
1818
{
1919
$model = new ExampleModel();
2020

@@ -25,7 +25,7 @@ public function testModelFindAll()
2525
$this->assertCount(3, $objects);
2626
}
2727

28-
public function testSoftDeleteLeavesRow()
28+
public function testSoftDeleteLeavesRow(): void
2929
{
3030
$model = new ExampleModel();
3131
$this->setPrivateProperty($model, 'useSoftDeletes', true);

admin/starter/tests/session/ExampleSessionTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99
final class ExampleSessionTest extends CIUnitTestCase
1010
{
11-
public function testSessionSimple()
11+
public function testSessionSimple(): void
1212
{
1313
$session = Services::session();
1414

admin/starter/tests/unit/HealthTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@
1010
*/
1111
final class HealthTest extends CIUnitTestCase
1212
{
13-
public function testIsDefinedAppPath()
13+
public function testIsDefinedAppPath(): void
1414
{
1515
$this->assertTrue(defined('APPPATH'));
1616
}
1717

18-
public function testBaseUrlHasBeenSet()
18+
public function testBaseUrlHasBeenSet(): void
1919
{
2020
$validation = Services::validation();
2121

0 commit comments

Comments
 (0)