Skip to content

Commit 8a5fa25

Browse files
committed
CS/Tweak tests
1 parent 794d6c1 commit 8a5fa25

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

.gitattributes

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# Path-based git attributes
2+
# https://www.kernel.org/pub/software/scm/git/docs/gitattributes.html
3+
4+
# Ignore all test and documentation with "export-ignore".
5+
/.gitattributes export-ignore
6+
/.gitignore export-ignore
7+
/.travis.yml export-ignore
8+
/phpunit.xml export-ignore
9+
/tests export-ignore

phpunit.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<phpunit backupGlobals="false"
33
backupStaticAttributes="false"
4-
bootstrap="phpunit.php"
4+
bootstrap="vendor/autoload.php"
55
colors="true"
66
convertErrorsToExceptions="true"
77
convertNoticesToExceptions="true"
@@ -22,4 +22,4 @@
2222
<directory>./src</directory>
2323
</whitelist>
2424
</filter>
25-
</phpunit>
25+
</phpunit>

src/Extension/Validation/ValidationListener.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,6 @@ protected function findRules(FormInterface $parent, $rules = [], $parentName = n
8585
$innerType = $form->getConfig()->getType()->getInnerType();
8686

8787
if ($config->hasOption('rules')) {
88-
8988
if ($parentName !== null) {
9089
$name = $parentName . '.' . $name;
9190
} elseif (! $parent->isRoot()) {
@@ -97,7 +96,7 @@ protected function findRules(FormInterface $parent, $rules = [], $parentName = n
9796

9897
if ($innerType instanceof CollectionType) {
9998
$children = $form->all();
100-
if(isset($children[0])) {
99+
if (isset($children[0])) {
101100
$rules = $this->findRules($children[0], $rules, $name . '.*');
102101
}
103102
}

0 commit comments

Comments
 (0)