Fix style and phpdoc
Fix randomly failing spec
Fix PMD
Merge pull request #1626 from akeneo/static-analysis-fix

Static analysis fixes