File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 5353 - name : PHPStan
5454 run : phpstan analyse --no-progress
5555
56- phpunit-lowest :
56+ phpunit :
5757 runs-on : ubuntu-latest
5858 name : PHP 7.4 Test on ubuntu-latest
5959 steps :
7878 restore-keys : ${{ runner.os }}-composer-
7979
8080 - name : Install dependencies
81- run : composer update --prefer-dist --prefer-lowest
81+ run : composer install --prefer-dist
8282
8383 - name : " Run tests with phpunit/phpunit"
8484 env :
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ metrics:
3131 vendor/bin/phpmetrics --report-html=build/phpmetrics.html src
3232
3333phpstan :
34- vendor/bin/phpstan analyse src --level=6 -c phpstan.neon
34+ vendor/bin/phpstan analyse -c phpstan.neon
3535
3636# ================================
3737# TEST
Original file line number Diff line number Diff line change @@ -3,7 +3,8 @@ includes:
33 - vendor/phpstan/phpstan-symfony/rules.neon
44
55parameters :
6- level : 5
7- paths :
8- - src
9- - tests
6+ checkMissingIterableValueType : false
7+ level : 6
8+ paths :
9+ - src
10+ - tests
Original file line number Diff line number Diff line change @@ -105,15 +105,15 @@ public function getId()
105105 /**
106106 * {@inheritdoc}
107107 */
108- public function getUsername ()
108+ public function getUsername (): string
109109 {
110110 return $ this ->email ;
111111 }
112112
113113 /**
114114 * {@inheritdoc}
115115 */
116- public function getEmail ()
116+ public function getEmail (): string
117117 {
118118 return $ this ->email ;
119119 }
@@ -133,7 +133,7 @@ public function setEmail($email)
133133 /**
134134 * {@inheritdoc}
135135 */
136- public function getPassword ()
136+ public function getPassword (): string
137137 {
138138 return $ this ->password ;
139139 }
@@ -181,7 +181,7 @@ public function setPlainPassword($plainPassword)
181181 /**
182182 * {@inheritdoc}
183183 */
184- public function eraseCredentials ()
184+ public function eraseCredentials (): void
185185 {
186186 $ this ->plainPassword = null ;
187187 }
Original file line number Diff line number Diff line change 1111 */
1212class UserTraitTest extends TestCase
1313{
14- public function testFullname ()
14+ public function testFullname (): void
1515 {
1616 $ user = new User ();
1717 $ user ->setLastName ('Doe ' )
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ protected function getValidatorInstance()
2525 * @param string $expectedMessage
2626 * @dataProvider failPasswordProvider
2727 */
28- public function testValidationFail ($ value , $ expectedMessage )
28+ public function testValidationFail ($ value , $ expectedMessage ): void
2929 {
3030 $ constraint = new IsPasswordSafe ();
3131 $ validator = $ this ->initValidator ($ expectedMessage );
@@ -52,7 +52,7 @@ public function failPasswordProvider()
5252 * @param string $value
5353 * @dataProvider validPasswordProvider
5454 */
55- public function testValidationOk ($ value )
55+ public function testValidationOk ($ value ): void
5656 {
5757 $ constraint = new IsPasswordSafe ();
5858 $ validator = $ this ->initValidator ();
You can’t perform that action at this time.
0 commit comments