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

Test namespace flags of 'bud' subcommand #3173

Merged
merged 2 commits into from
Apr 27, 2021

Conversation

hshiina
Copy link
Contributor

@hshiina hshiina commented Apr 21, 2021

Signed-off-by: Hironori Shiina [email protected]

What type of PR is this?

/kind other

What this PR does / why we need it:

Add 'bud' subcommand to the 'namespaces' system test, which already verifies namespace flags with 'from' and 'run' subcommands.

How to verify it

Run the system test: bats tests/namespaces.bats

Which issue(s) this PR fixes:

None

Special notes for your reviewer:

Does this PR introduce a user-facing change?

None

Add 'bud' subcommand to the 'namespaces' system test, which already
verifies namespace flags with 'from' and 'run' subcommands.

Signed-off-by: Hironori Shiina <[email protected]>
@rhatdan
Copy link
Member

rhatdan commented Apr 22, 2021

@openshift-ci-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hshiina, rhatdan

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@cevich
Copy link
Member

cevich commented Apr 22, 2021

LGTM but I'm not an expert in these test. @edsantiago will this new test need any special treatment for reuse in the 'bud' testing for podman?

Copy link
Member

@edsantiago edsantiago left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM at first pass, but this requires more than one pass: it's pretty complicated. ITM I have one request. It may turn out to be impossible or too difficult to refactor, that's ok, but I'd like to know that at least it has been considered.

Comment on lines +209 to +211


# Also test bud command
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The idmapping test was unmaintainable even before this addition; it is now even more so. I like the addition, and it is well done, but I wonder if you could take some time to find a way to refactor this, perhaps by crafting one or more smaller helper functions?

@edsantiago
Copy link
Member

@cevich this will never run under podman. Podman only tests bud.bats, and these tests are in namespaces.bats

Introduce helper functions for the same check between 'from and run'
and 'bud'.

Signed-off-by: Hironori Shiina <[email protected]>
@edsantiago
Copy link
Member

Oh, nice, thank you! It'll take me a while to review in depth, but I fully intend to do so this morning!

@edsantiago
Copy link
Member

/lgtm

Nice work!

@openshift-merge-robot openshift-merge-robot merged commit 1065fd2 into containers:master Apr 27, 2021
edsantiago added a commit to edsantiago/buildah that referenced this pull request Apr 27, 2021
Followup to containers#3173 - just a little further cleanup of idmapping
test. Plus, oops, fix a longstanding error-failure bug

Signed-off-by: Ed Santiago <[email protected]>
@hshiina hshiina deleted the bud-namespace branch April 27, 2021 21:05
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants