-
Notifications
You must be signed in to change notification settings - Fork 8
Enable tar/zip/git client testing to be compatible with external repo files. #79
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Leander Stephen D'Souza <[email protected]>
59ad8cb to
3ee051d
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #79 +/- ##
=======================================
Coverage 26.98% 26.98%
=======================================
Files 31 31
Lines 2238 2238
Branches 392 392
=======================================
Hits 604 604
Misses 1574 1574
Partials 60 60 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR modifies the test infrastructure to support testing git, tar, and zip clients using external repository files. Instead of creating synthetic test repositories and archives, the tests now use the original list_repos.yaml file which references the actual vcs2l repository on GitHub, with archives and repositories created by cloning and checking out specific commits.
Key changes:
- Replaced synthetic test data generation with dynamic repository/archive creation based on external repos file
- Added helper functions to create git repositories and tar/zip archives by cloning and checking out target commits
- Updated all expected test outputs to reflect actual commit hashes and repository metadata from the external repository
Reviewed Changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| test/init.py | Added helper functions for repository/archive creation and modified StagedReposFile to use external repos file |
| test/test_commands.py | Updated TestCommands to use LIST_REPOS_FILE and removed repos_file_url references |
| test/list_repos.yaml | Added the original list.repos file with actual vcs2l repository references |
| test/*.txt | Updated expected test outputs to reflect actual commit hashes and file paths from external repository |
| .github/workflows/ci.yml | Added fetch-depth: 0 to checkout action for full git history |
Signed-off-by: Leander Stephen D'Souza <[email protected]>
3ee051d to
a6c5864
Compare
a6c5864 to
fe267de
Compare
Signed-off-by: Leander Stephen D'Souza <[email protected]>
fe267de to
a2b9b3e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 15 out of 15 changed files in this pull request and generated 2 comments.
Basic Info
Description of contribution in a few bullet points
Expose testing of git, tar, and zip clients to be compatible with any external repo list file.
Added helper functions for these clients to create repositories/archives by locally cloning the repository, and checking them out to their target hashes before archiving.
Add the original
list_repos.yamlback into testing, and modified the expected output to match the interaction with this file instead.Use a remote clone as the
codecovworkflow sparsely checks out the branch under a single commit.Description of how this change was tested
pre-commit run --allpython3 -m pytest -s -v test