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

fix: ensure usrlocalsharelima.Dir() works when called from tests #3401

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

Konikz
Copy link

@Konikz Konikz commented Apr 3, 2025

Fixes #3208

During tests, usrlocalsharelima.Dir() fails to find the guestagent binary because the test executable is in a temp directory. This PR adds a test that verifies the binary can be found in both expected locations:

  1. Same directory as the test executable
  2. share/lima directory relative to the test executable

The test creates dummy binaries in both locations and verifies Dir() can find them. This ensures the function works correctly in test environments where os.Executable returns a temp directory path.

Konikz added 5 commits March 26, 2025 13:36
Added README.md for Lima VM Plugin Subsystem Contribution  

- Documented the VM Plugin Subsystem implementation, highlighting the decoupling of VM drivers (`qemu`, `vz`, `wsl2`) via gRPC.  
- Provided details on the gRPC interface, plugin framework, and driver migration.  
- Addressed test failures from the main Lima repo, inviting maintainers to review and collaborate on improvements.  
- Introduced myself as a newcomer to open source, emphasizing my eagerness to learn and contribute.  

This README aims to provide CNCF Lima mentors and contributors with a clear understanding of my work and request for feedback.
@jandubois
Copy link
Member

There is something wrong with this PR; it adds almost 2000 lines, many unrelated to the issue it is supposed to fix. This may be responsible for the various test failures.

Don't merge master into your branch, but rebase on latest master if there are merge conflicts.

Please squash commits into a single commit and add a DCO signature.

Thanks!

@jandubois jandubois marked this pull request as draft April 10, 2025 01:17
@jandubois
Copy link
Member

There is something wrong with this PR; it adds almost 2000 lines, many unrelated to the issue it is supposed to fix. This may be responsible for the various test failures.

@Konikz Are you planning to fix this PR? There is nothing we can do with it until the extraneous commits are removed and the lint failures addressed.

@Konikz
Copy link
Author

Konikz commented Apr 10, 2025

@jandubois I'll rectify the issue with the pr

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.

usrlocalsharelima.Dir() doesn't work when called from tests
2 participants