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

Add coverage test #96

Merged
merged 3 commits into from
Aug 24, 2022
Merged

Add coverage test #96

merged 3 commits into from
Aug 24, 2022

Conversation

afunTW
Copy link
Collaborator

@afunTW afunTW commented Aug 24, 2022

Summary

Under the pytest framework with pytest-cov module, the output will be like the following message

---------- coverage: platform linux, python 3.8.10-final-0 -----------
Name                         Stmts   Miss  Cover
------------------------------------------------
proxybroker/__init__.py         22      0   100%
proxybroker/api.py             229    196    14%
proxybroker/checker.py         209    185    11%
proxybroker/errors.py           24      0   100%
proxybroker/judge.py            78     60    23%
proxybroker/negotiators.py      96      4    96%
proxybroker/providers.py       358    215    40%
proxybroker/proxy.py           217     58    73%
proxybroker/resolver.py         93     12    87%
proxybroker/server.py          245    218    11%
proxybroker/utils.py            83     22    73%
tests/__init__.py                0      0   100%
tests/conftest.py               49      6    88%
tests/test_negotiators.py       58      0   100%
tests/test_proxy.py            173      0   100%
tests/test_resolver.py          65      0   100%
tests/test_utils.py             24      0   100%
tests/utils.py                   8      0   100%
------------------------------------------------
TOTAL                         2031    976    52%

@afunTW
Copy link
Collaborator Author

afunTW commented Aug 24, 2022

I figure out that the CI flow all depends on poetry.lock, which should be define in CONTRIBUTE.md. The Ci failed because I updated the requirements/ only

@afunTW afunTW changed the title Add coverage test WIP: Add coverage test Aug 24, 2022
@bluet
Copy link
Owner

bluet commented Aug 24, 2022

oops tests are failing https://github.com/bluet/proxybroker2/runs/7989566629?check_suite_focus=true#step:9:14

pytest: error: unrecognized arguments: --cov

@sonarcloud
Copy link

sonarcloud bot commented Aug 24, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@afunTW afunTW changed the title WIP: Add coverage test Add coverage test Aug 24, 2022
@bluet
Copy link
Owner

bluet commented Aug 24, 2022

LGTM

@bluet bluet merged commit 08bac31 into master Aug 24, 2022
@bluet bluet deleted the feature/add-pytest-cov branch August 24, 2022 08:32
@hms5232
Copy link

hms5232 commented Aug 26, 2022

I figure out that the CI flow all depends on poetry.lock, which should be define in CONTRIBUTE.md. The Ci failed because I updated the requirements/ only

related #93 (comment)

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.

3 participants