Add mount invariant test for FleetJobPaths COS-to-container paths#2210
Open
avilches wants to merge 5 commits into
Open
Add mount invariant test for FleetJobPaths COS-to-container paths#2210avilches wants to merge 5 commits into
avilches wants to merge 5 commits into
Conversation
avilches
commented
Jun 9, 2026
Contributor
Author
|
Tests were green, which shows that the code was correct. Now I'm changing the PR to add the refactor while keeping the test unchanged. I'm resolving conflicts and squash commit because the branch base change. |
2f08269 to
79967fd
Compare
Contributor
Author
|
Refactor looks horrible, so close it. So, I would just keep this test only. |
Contributor
Author
|
@ElePT @marceloamaral quick approve to merge plis? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
test_cos_to_container_mount_invarianttotest_fleet_utils.pyto verify that every(cos_key, cos_prefix)pair inFleetJobPathsresolves to the expected container path after PDS mounting.The invariant: if a COS key is
{prefix}/{filename}andprefixis mounted atmount_point, the container path must bemount_point/{filename}. Currently nothing catches a change to one side (e.g. renaming a COS prefix) without updating the other (the container path), so this test closes that gap.The test covers all 9 relevant pairs across both custom jobs (4 cases) and provider jobs (5 cases, including the private log) in a single table-driven assertion: