Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implemented canLogIn check for authenticate method. FIXES #52 #53

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bummzack
Copy link
Contributor

The login method itself already checks canLogIn, deeply covered in MemberAuthenticator::authenticate, so only authenticate had to be fixed.

Added a test to RESTfulAPI_TokenAuthenticator_Test that checks both authentication methods (login & authenticate) for canLogIn.

Added tests to check `canLogIn` calls.
* Extension to test "canLogin"
*/
class TestCanLoginExtension extends DataExtension
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be cleaner to have this as a different file and rename the class to follow the same pattern as the other ones like RESTfulAPI_CanLogInExtension_Test.php

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's only being used for this test-case.. so moving it to an external file seems counter-intuitive as it makes understanding of the test more difficult. As for naming, feel free to rename it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants