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

Use {testthat} for mock testing #2395

Merged
merged 8 commits into from
Dec 6, 2023
Merged

Use {testthat} for mock testing #2395

merged 8 commits into from
Dec 6, 2023

Conversation

IndrajeetPatil
Copy link
Collaborator

@IndrajeetPatil IndrajeetPatil commented Dec 5, 2023

No description provided.

@MichaelChirico
Copy link
Collaborator

{mockery} is superseded so either way we should refactor tests using it. New test looks fine anyway! Thanks for tackling. Be sure to remove {mockery} from Suggests afterwards.

@codecov-commenter
Copy link

codecov-commenter commented Dec 5, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (8ae6da6) 99.10% compared to head (9f72235) 99.10%.

❗ Current head 9f72235 differs from pull request most recent head 9c6f9c8. Consider uploading reports for the commit 9c6f9c8 to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2395   +/-   ##
=======================================
  Coverage   99.10%   99.10%           
=======================================
  Files         125      125           
  Lines        5671     5671           
=======================================
  Hits         5620     5620           
  Misses         51       51           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@IndrajeetPatil IndrajeetPatil marked this pull request as ready for review December 5, 2023 18:29
@IndrajeetPatil IndrajeetPatil changed the title WIP: Use {testthat} for mock testing Use {testthat} for mock testing Dec 5, 2023
@IndrajeetPatil IndrajeetPatil added internals Issues related to inner workings of lintr, i.e., not user-visible testing labels Dec 5, 2023
MichaelChirico
MichaelChirico previously approved these changes Dec 6, 2023
Copy link
Collaborator

@MichaelChirico MichaelChirico left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for taking this on!

A small comment about if (x, ...) is needed (it was ... before) in two places. Feel free to merge if there's no change needed.

@MichaelChirico MichaelChirico merged commit fbadcfc into main Dec 6, 2023
20 checks passed
@MichaelChirico MichaelChirico deleted the use-testthat-mocking branch December 6, 2023 02:07
@IndrajeetPatil IndrajeetPatil linked an issue Dec 6, 2023 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internals Issues related to inner workings of lintr, i.e., not user-visible testing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use {testthat} for mock testing
3 participants