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

Simplify tests verifying the modules - [opened] #7

Open
sigmavirus24 opened this issue Oct 13, 2021 · 1 comment
Open

Simplify tests verifying the modules - [opened] #7

sigmavirus24 opened this issue Oct 13, 2021 · 1 comment

Comments

@sigmavirus24
Copy link
Member

In GitLab by @xZise on Jul 26, 2016, 04:54

Merges simplify-checks -> master

The test which verifies the modules dict first checked if the length was
correctly set and then checked the contents. But by checking the contents it
also checks the length so that check is obsolete. Additional does the check of
two lists show explicitly which elements are different between the lists:

>       assert stdin.modules['pep8'] == [pep8]
E       assert [<module 'pep...8.py'>, False] == [<module
'pep8...ges/pep8.py'>]
E         Left contains more items, first extra item: False
E         Use -v to get the full diff

But the original implementation at least shows the content of the list:

>       assert len(stdin.modules['pep8']) == 1
E       assert 2 == 1
E        +  where 2 = len([<module 'pep8...8.py'>, False])
@sigmavirus24
Copy link
Member Author

In GitLab by @pycqa-jenkins on Jul 26, 2016, 04:55

👎 Jenkins Build Failed

Results available at: Jenkins [Flake8 Pollyfill's CI Pipeline #9]

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

No branches or pull requests

1 participant