@@ -951,17 +951,13 @@ public function amOnAction(string $action, array $params = [])
951
951
952
952
/**
953
953
* Checks that a user is authenticated.
954
- * You can check users logged in with the option 'remember me' passing true as parameter.
955
954
*
956
955
* ```php
957
956
* <?php
958
957
* $I->seeAuthentication();
959
- * $I->seeAuthentication(true);
960
958
* ```
961
- *
962
- * @param bool $remembered
963
959
*/
964
- public function seeAuthentication (bool $ remembered = false )
960
+ public function seeAuthentication ()
965
961
{
966
962
$ security = $ this ->grabService ('security.helper ' );
967
963
@@ -971,9 +967,7 @@ public function seeAuthentication(bool $remembered = false)
971
967
$ this ->fail ('There is no user in session ' );
972
968
}
973
969
974
- $ role = $ remembered ? 'IS_AUTHENTICATED_REMEMBERED ' : 'IS_AUTHENTICATED_FULLY ' ;
975
-
976
- $ this ->assertTrue ($ security ->isGranted ($ role ), 'There is no authenticated user ' );
970
+ $ this ->assertTrue ($ security ->isGranted ('IS_AUTHENTICATED_FULLY ' ), 'There is no authenticated user ' );
977
971
}
978
972
979
973
/**
@@ -1039,23 +1033,18 @@ public function seeUserHasRole(string $role)
1039
1033
1040
1034
/**
1041
1035
* Check that user is not authenticated.
1042
- * You can specify whether users logged in with the 'remember me' option should be ignored by passing 'false' as a parameter.
1043
1036
*
1044
1037
* ```php
1045
1038
* <?php
1046
1039
* $I->dontSeeAuthentication();
1047
1040
* ```
1048
- *
1049
- * @param bool $remembered
1050
1041
*/
1051
- public function dontSeeAuthentication (bool $ remembered = true )
1042
+ public function dontSeeAuthentication ()
1052
1043
{
1053
1044
$ security = $ this ->grabService ('security.helper ' );
1054
1045
1055
- $ role = $ remembered ? 'IS_AUTHENTICATED_REMEMBERED ' : 'IS_AUTHENTICATED_FULLY ' ;
1056
-
1057
1046
$ this ->assertFalse (
1058
- $ security ->isGranted ($ role ),
1047
+ $ security ->isGranted (' IS_AUTHENTICATED_FULLY ' ),
1059
1048
'There is an user authenticated '
1060
1049
);
1061
1050
}
0 commit comments