Skip to content
This repository was archived by the owner on Jun 11, 2020. It is now read-only.

Commit 82ae9e9

Browse files
committed
update phpunit config. format codes
1 parent 4d0194f commit 82ae9e9

File tree

4 files changed

+23
-18
lines changed

4 files changed

+23
-18
lines changed

composer.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22
"name": "toolkit/arr-utils",
33
"type": "library",
44
"description": "some array tool library of the php",
5-
"keywords": ["library","tool","php"],
5+
"keywords": [
6+
"library",
7+
"tool",
8+
"php"
9+
],
610
"homepage": "https://github.com/php-toolkit/arr-utils",
711
"license": "MIT",
812
"authors": [
@@ -17,7 +21,7 @@
1721
},
1822
"autoload": {
1923
"psr-4": {
20-
"Toolkit\\ArrUtil\\" : "src/"
24+
"Toolkit\\ArrUtil\\": "src/"
2125
}
2226
},
2327
"suggest": {

phpunit.xml.dist

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,16 @@
88
convertNoticesToExceptions="true"
99
convertWarningsToExceptions="true"
1010
stopOnFailure="false"
11-
syntaxCheck="false"
1211
>
13-
<testsuites>
14-
<testsuite name="Php Library Test Suite">
15-
<directory>test/</directory>
16-
</testsuite>
17-
</testsuites>
12+
<testsuites>
13+
<testsuite name="Php Library Test Suite">
14+
<directory>test/</directory>
15+
</testsuite>
16+
</testsuites>
1817

19-
<filter>
20-
<whitelist>
21-
<directory suffix=".php">src</directory>
22-
</whitelist>
23-
</filter>
18+
<filter>
19+
<whitelist>
20+
<directory suffix=".php">src</directory>
21+
</whitelist>
22+
</filter>
2423
</phpunit>

src/ArrayHelper.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -877,7 +877,8 @@ public static function toString(
877877
$addMark = false,
878878
$separator = ', ',
879879
$string = ''
880-
): string {
880+
): string
881+
{
881882
if (!\is_array($array) || empty($array)) {
882883
return '';
883884
}
@@ -922,7 +923,8 @@ public static function toStringNoKey(
922923
$showKey = false,
923924
$addMark = true,
924925
$separator = ', '
925-
): string {
926+
): string
927+
{
926928
return static::toString($array, $length, $cycles, $showKey, $addMark, $separator);
927929
}
928930

test/boot.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@
1010
spl_autoload_register(function ($class) {
1111
$file = null;
1212

13-
if (0 === strpos($class,'Toolkit\ArrUtil\Example\\')) {
13+
if (0 === strpos($class, 'Toolkit\ArrUtil\Example\\')) {
1414
$path = str_replace('\\', '/', substr($class, strlen('Toolkit\ArrUtil\Example\\')));
1515
$file = dirname(__DIR__) . "/example/{$path}.php";
16-
} elseif (0 === strpos($class,'Toolkit\ArrUtil\Test\\')) {
16+
} elseif (0 === strpos($class, 'Toolkit\ArrUtil\Test\\')) {
1717
$path = str_replace('\\', '/', substr($class, strlen('Toolkit\ArrUtil\Test\\')));
1818
$file = __DIR__ . "/{$path}.php";
19-
} elseif (0 === strpos($class,'Toolkit\ArrUtil\\')) {
19+
} elseif (0 === strpos($class, 'Toolkit\ArrUtil\\')) {
2020
$path = str_replace('\\', '/', substr($class, strlen('Toolkit\ArrUtil\\')));
2121
$file = dirname(__DIR__) . "/src/{$path}.php";
2222
}

0 commit comments

Comments
 (0)