Skip to content

Commit ceb78d2

Browse files
committed
chore: apply cs to tests
1 parent 08c67d5 commit ceb78d2

File tree

30 files changed

+91
-98
lines changed

30 files changed

+91
-98
lines changed

tests/bootstrap.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
defined('YII_DEBUG') || define('YII_DEBUG', true);
34
defined('YII_ENV') || define('YII_ENV', 'test');
45

tests/cases/closeConnections/config.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
return [
34
'id' => 'Simple',
45
'basePath' => __DIR__,
@@ -9,4 +10,4 @@
910
'dsn' => 'sqlite:' . \tests\helpers\SqlliteHelper::getTmpFile(),
1011
],
1112
],
12-
];
13+
];

tests/cases/closeConnections/fixtures/EmptyFixture.php

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,7 @@
88

99
class EmptyFixture extends DbFixture
1010
{
11-
public function load()
12-
{
13-
}
11+
public function load() {}
1412

15-
public function unload()
16-
{
17-
}
18-
}
13+
public function unload() {}
14+
}

tests/cases/closeConnections/functional/FixturesCest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,4 @@ public function NoConnections(FunctionalTester $I, Example $example)
3434
$I->assertSame(SqlliteHelper::connectionCount(), $example['count']);
3535
}
3636

37-
}
37+
}

tests/cases/closeConnections/functional/FixturesInBeforeCest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,4 @@ public function NoConnections(FunctionalTester $I, Example $example)
3434
$I->assertSame(SqlliteHelper::connectionCount(), $example['count']);
3535
}
3636

37-
}
37+
}

tests/cases/closeConnections/functional/NoFixturesCest.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010

1111
class NoFixturesCest
1212
{
13-
1413
protected function numberProvider()
1514
{
1615
return array_pad([], 5, ['count' => 0]);
@@ -24,4 +23,4 @@ public function NoConnections(FunctionalTester $I, Example $example)
2423
{
2524
$I->assertSame(SqlliteHelper::connectionCount(), $example['count']);
2625
}
27-
}
26+
}

tests/cases/closeConnections/helpers/SqlliteHelper.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public static function connectionCount()
2020
{
2121
$path = self::$temp_name;
2222
$count = shell_exec("lsof -w {$path} | grep {$path} | wc -l");
23-
return (int)$count;
23+
return (int) $count;
2424
}
2525

2626
public static function debug()
@@ -31,4 +31,4 @@ public static function debug()
3131
codecept_debug(shell_exec($cmd));
3232
}
3333

34-
}
34+
}

tests/cases/closeConnectionsNoCleanup/config.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
return [
34
'id' => 'Simple',
45
'basePath' => __DIR__,
@@ -9,4 +10,4 @@
910
'dsn' => 'sqlite:' . \tests\helpers\SqlliteHelper::getTmpFile(),
1011
],
1112
],
12-
];
13+
];

tests/cases/closeConnectionsNoCleanup/functional/FixturesCest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,4 @@ public function NoConnections3(FunctionalTester $I)
3737
$I->assertSame(0, $count);
3838
}
3939

40-
}
40+
}

tests/cases/closeConnectionsNoCleanup/functional/FixturesInBeforeCest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,4 @@ public function OnlyOneConnection3(FunctionalTester $I)
3636
$count = SqlliteHelper::connectionCount();
3737
$I->assertSame(1, $count);
3838
}
39-
}
39+
}

0 commit comments

Comments
 (0)