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

Increase test coverage #503

Merged
merged 7 commits into from
Jul 1, 2021
Merged

Conversation

l0b0
Copy link
Contributor

@l0b0 l0b0 commented Jun 30, 2021

Related Issue(s): #331

Description:

PR Checklist:

  • Code is formatted (run pre-commit run --all-files)
  • Tests pass (run scripts/test)
  • Documentation has been updated to reflect changes, if applicable
  • This PR maintains or improves overall codebase code coverage.
  • Changes are added to the CHANGELOG. See the docs for information about adding to the changelog.

@codecov-commenter
Copy link

codecov-commenter commented Jun 30, 2021

Codecov Report

Merging #503 (de29122) into main (94d4426) will increase coverage by 0.10%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #503      +/-   ##
==========================================
+ Coverage   95.54%   95.65%   +0.10%     
==========================================
  Files          71       71              
  Lines       10008     9979      -29     
==========================================
- Hits         9562     9545      -17     
+ Misses        446      434      -12     
Impacted Files Coverage Δ
tests/extensions/test_sar.py 100.00% <ø> (+0.90%) ⬆️
tests/extensions/test_scientific.py 100.00% <ø> (+0.31%) ⬆️
tests/extensions/test_version.py 100.00% <ø> (+0.29%) ⬆️
tests/serialization/test_identify.py 100.00% <100.00%> (+3.22%) ⬆️
tests/test_version.py 100.00% <100.00%> (+4.00%) ⬆️
tests/test_writing.py 100.00% <100.00%> (+3.70%) ⬆️
tests/validation/test_validate.py 100.00% <100.00%> (+3.61%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 94d4426...de29122. Read the comment docs.

@l0b0 l0b0 marked this pull request as ready for review June 30, 2021 08:51
Copy link
Contributor

@duckontheweb duckontheweb left a comment

Choose a reason for hiding this comment

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

A couple of comments that are more like questions, but I'm happy merging this as-is.

l0b0 added 7 commits July 1, 2021 09:28
This subtracts from coverage, and it's not much of a time saver:
`python tests/extensions/test_version.py` isn't much less typing than
`python -m unittest tests/extensions/test_version.py`.
`if not is_valid` can't happen, because
`is_valid = not is_absolute_href(asset.href)` and the condition above that
line is `if not is_absolute_href(asset.href):`. Conversely, since
`is_valid` is always `True` there is no point in
`self.assertTrue(is_valid)`.
Presumably versions < 0.8 are no longer supported.
@l0b0 l0b0 force-pushed the increase-test-coverage branch from e5abc06 to de29122 Compare June 30, 2021 23:42
@duckontheweb duckontheweb merged commit 0426bd1 into stac-utils:main Jul 1, 2021
@l0b0 l0b0 deleted the increase-test-coverage branch July 1, 2021 02:49
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.

4 participants