@@ -216,7 +216,7 @@ incorrect.
216216By using test cases you can describe the relationship between a set of
217217known inputs and their expected output. This helps you be more confident of the
218218code you're writing as you can ensure that the code you wrote fulfills the
219- expectations and assertions your tests make. Additionally because tests are
219+ expectations and assertions your tests make. Additionally, because tests are
220220code, they can be re-run whenever you make a change. This helps prevent
221221the creation of new bugs.
222222
@@ -548,19 +548,19 @@ class ArticlesFixture extends TestFixture
548548{
549549 // Optional. Set this property to load fixtures
550550 // to a different test datasource
551- public $connection = 'test';
551+ public string $connection = 'test';
552552
553553 // Optional. Lets you define which table alias is used when
554554 // reflecting schema and inserting rows. Inferred from the
555555 // class name by default. Added in 5.3.0
556- public $tableAlias = 'Articles';
556+ public string $tableAlias = 'Articles';
557557
558558 // Optional. Lets you define the table name for a fixture.
559559 // If defined, this table name will be camelized to create
560560 // $tableAlias.
561- public $table = 'articles';
561+ public string $table = 'articles';
562562
563- public $records = [
563+ public array $records = [
564564 [
565565 'title' => 'First Article',
566566 'body' => 'First Article Body',
@@ -617,7 +617,7 @@ use Cake\TestSuite\Fixture\TestFixture;
617617
618618class ArticlesFixture extends TestFixture
619619{
620- protected $strictFields = true;
620+ protected bool $strictFields = true;
621621
622622 // rest of fixture
623623}
@@ -671,7 +671,7 @@ you define the `$fixtures` property in your model:
671671``` php
672672class ArticlesTest extends TestCase
673673{
674- protected $fixtures = ['app.Articles', 'app.Comments'];
674+ protected array $fixtures =['app.Articles', 'app.Comments'];
675675}
676676```
677677
@@ -694,7 +694,7 @@ Fixture directory. You can also load fixtures from CakePHP core, or plugins:
694694``` php
695695class ArticlesTest extends TestCase
696696{
697- protected $fixtures = [
697+ protected array $fixtures =[
698698 'plugin.DebugKit.Articles',
699699 'plugin.MyVendorName/MyPlugin.Messages',
700700 'core.Comments',
@@ -713,7 +713,7 @@ name:
713713``` php
714714class ArticlesTest extends CakeTestCase
715715{
716- protected $fixtures = ['app.Blog/Articles', 'app.Blog/Comments'];
716+ protected array $fixtures =['app.Blog/Articles', 'app.Blog/Comments'];
717717}
718718```
719719
@@ -926,7 +926,7 @@ use Cake\TestSuite\TestCase;
926926
927927class ArticlesTableTest extends TestCase
928928{
929- protected $fixtures = ['app.Articles'];
929+ protected array $fixtures =['app.Articles'];
930930}
931931```
932932
@@ -948,7 +948,7 @@ use Cake\TestSuite\TestCase;
948948
949949class ArticlesTableTest extends TestCase
950950{
951- protected $fixtures = ['app.Articles'];
951+ protected array $fixtures =['app.Articles'];
952952
953953 public function setUp(): void
954954 {
@@ -1100,7 +1100,7 @@ class ArticlesControllerTest extends TestCase
11001100{
11011101 use IntegrationTestTrait;
11021102
1103- protected $fixtures = ['app.Articles'];
1103+ protected array $fixtures =['app.Articles'];
11041104
11051105 public function testIndex(): void
11061106 {
@@ -1976,7 +1976,7 @@ use Cake\TestSuite\TestCase;
19761976
19771977class OrdersTableTest extends TestCase
19781978{
1979- protected $fixtures = ['app.Orders'];
1979+ protected array $fixtures =['app.Orders'];
19801980
19811981 public function setUp(): void
19821982 {
@@ -2062,7 +2062,7 @@ use Cake\TestSuite\TestCase;
20622062class BlogPostsTableTest extends TestCase
20632063{
20642064 // Plugin fixtures located in /plugins/Blog/tests/Fixture/
2065- protected $fixtures = ['plugin.Blog.BlogPosts'];
2065+ protected array $fixtures =['plugin.Blog.BlogPosts'];
20662066
20672067 public function testSomething(): void
20682068 {
@@ -2073,7 +2073,7 @@ class BlogPostsTableTest extends TestCase
20732073
20742074If you want to use plugin fixtures in the app tests you can
20752075reference them using ` plugin.pluginName.fixtureName ` syntax in the
2076- ` $fixtures ` array. Additionally if you use vendor plugin name or fixture
2076+ ` $fixtures ` array. Additionally, if you use vendor plugin name or fixture
20772077directories you can use the following: ` plugin.vendorName/pluginName.folderName/fixtureName ` .
20782078
20792079Before you can use fixtures you should ensure you have the [ fixture
0 commit comments