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 #906

Merged
merged 2 commits into from
Sep 12, 2024
Merged

Increase test coverage #906

merged 2 commits into from
Sep 12, 2024

Conversation

nikosbosse
Copy link
Contributor

@nikosbosse nikosbosse commented Sep 11, 2024

Description

This PR increases test coverage by

  • adding tests
  • removing a bunch of unnecessary test_forecast_type_is... functions. I think we previously used this to automagically determine the forecast type in get_forecast_type(), but that's handled via classes now.

Remaining difference between actual codecov and 100% is due to

  • some code in permutation_test() that can't actually ever be reached (I mean it could, but the way we're calling it internally it can't). It could do with some cleaning up, but I'm a tired man...
  • the plot_pit() function has a genuine issue (see Testing: Make sure pit() and plot_pit() are correct #359). I didn't want to create a test that's technically working but ultimately wrong

Checklist

  • My PR is based on a package issue and I have explicitly linked it.
  • I have included the target issue or issues in the PR title as follows: issue-number: PR title
  • I have tested my changes locally.
  • I have added or updated unit tests where necessary.
  • I have updated the documentation if required.
  • I have built the package locally and run rebuilt docs using roxygen2.
  • My code follows the established coding standards and I have run lintr::lint_package() to check for style issues introduced by my changes.
  • I have added a news item linked to this PR.
  • I have reviewed CI checks for this PR and addressed them as far as I am able.

@nikosbosse nikosbosse requested a review from seabbs September 11, 2024 21:31
@seabbs
Copy link
Contributor

seabbs commented Sep 12, 2024

that can't actually ever be reached (I mean it could, but the way we're calling it internally it can't). It could do with some cleaning up, but I'm a tired man...

This is very funny

@nikosbosse
Copy link
Contributor Author

What can't be reached can't error at least :-D

Copy link
Contributor

@seabbs seabbs left a comment

Choose a reason for hiding this comment

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

Looks good. Missing a saved snapshot

@seabbs seabbs enabled auto-merge (squash) September 12, 2024 16:00
@seabbs seabbs merged commit 64f0ff1 into main Sep 12, 2024
9 checks passed
@seabbs seabbs deleted the code-coverage branch September 12, 2024 16:03
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