-
Notifications
You must be signed in to change notification settings - Fork 936
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: correctly find workspace.dependencies-declared dependencies and their Cargo.toml #5865
fix: correctly find workspace.dependencies-declared dependencies and their Cargo.toml #5865
Conversation
556b218
to
38435a0
Compare
I happened to have just created one in #5866, you can use it as an example. The fixture is the response from api.github.com for a Cargo.toml. So for instance https://api.github.com/repos/tokio-rs/bytes/contents/Cargo.toml would be a valid fixture. The In your test it will need to assert the array matches all the various Cargo.toml paths it should download. |
I will two need |
You can also bas64 encode the contents of a cargo.toml that you have locally and stick it in the fixtures manually. We stub out any requests to the github api with those fixtures, so they don't need to exist for real |
@poliorcetics Anything else we can do to unblock you here? |
gentle nudge @poliorcetics |
Checking in one last time @poliorcetics are you still interested in working on this? |
Sorry I completely forgot to answer before, I don't think I can finish this. For someone wanting to make it cross the finish line: the only thing left to do are tests |
38435a0
to
f796a03
Compare
Let me see if I can read up on |
f796a03
to
3991e88
Compare
@poliorcetics I did spend some time on this back in January, and ran into some issues with creating mocks of test code in Rust. The code seems straightforward, but the UT I'd added kept failing--the ruby looked fine, so I think I was misunderstanding something about how the rust cargo files should look. Which is probably on me, as your example in #5864 makes sense. Any chance you'd want to take another shot at writing a test, or at the very least push up an example repo or mock to help clarify? |
I would like help for writing a test, I have found
cargo/file_fetcher_spec.rb
, but I don'tunderstand how it works.
Closes #5864