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

Local scoping and local tempdirs for edge case test file #140

Merged
merged 2 commits into from Apr 27, 2024
Merged

Conversation

slager
Copy link
Contributor

@slager slager commented Apr 27, 2024

This test file created and sometimes deleted numerous test data packages in temporary directories, and had 300+ lines of test code all scoped inside the same testthat block. As such, it was confusing to follow and maybe prone to some hard-to-notice test inter-dependencies.

This PR splits up those tests into 11 different blocks, each with locally scoped variables and locally scoped auto-deleting temporary directories. This was needed prep for some upcoming refactoring I wanted to do, and will be useful for eventual re-organizing of the test files. There's still room to improve these tests, which didn't have many code comments.

This PR also renames config.yml to datapackager.yml in the documentation (inspired by finding an old instance of that filename lingering in the test code itself).

@slager slager merged commit 666928e into develop Apr 27, 2024
7 checks passed
@slager slager deleted the edge branch April 27, 2024 23:54
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.

None yet

1 participant