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

AutoTest: Introduce User named tuple. #484

Merged
merged 1 commit into from
Jul 3, 2016
Merged

AutoTest: Introduce User named tuple. #484

merged 1 commit into from
Jul 3, 2016

Conversation

kmeht
Copy link
Member

@kmeht kmeht commented Jul 3, 2016

(#475) The tuples used to specify users and expected errors were really confusing. We can use named tuples to make this more clear. We can also add some hackery so that the fields are optional (and set to None by default).

The tuples used to specify users and expected errors were really confusing. We can use named tuples to make this more clear. We can also add some hackery so that the fields are optional (and set to None by default).
User.__new__.__defaults__ = (None, None, None)


EXP_NOT_AUTHENTICATED = 'exp_not_authenticated'
Copy link
Contributor

Choose a reason for hiding this comment

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

As we add more errors, it might be a good idea to wrap this in a dictionary and call it expected_errors just so it's clearer we're referencing errors.

Copy link
Member Author

Choose a reason for hiding this comment

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

Noted! 👍

@kmeht kmeht merged commit c05c4ab into master Jul 3, 2016
@kmeht kmeht deleted the autouser branch July 3, 2016 05:37
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