test(docker): Add shell tests for the docker libraries. - #122
Open
jackluo923 wants to merge 1 commit into
Open
Conversation
Contributor
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
3 tasks
jackluo923
marked this pull request as draft
August 2, 2026 18:54
jackluo923
force-pushed
the
feat/ca-trust-tests
branch
2 times, most recently
from
August 2, 2026 19:01
79646c7 to
13da398
Compare
3 tasks
jackluo923
force-pushed
the
feat/ca-trust-tests
branch
3 times, most recently
from
August 2, 2026 19:17
16a8b88 to
f4ab355
Compare
jackluo923
force-pushed
the
feat/ca-trust-tests
branch
from
August 2, 2026 19:18
f4ab355 to
b8603c4
Compare
jackluo923
force-pushed
the
feat/ca-trust-tests
branch
from
August 2, 2026 22:21
b8603c4 to
b6b616d
Compare
jackluo923
force-pushed
the
feat/ca-trust-tests
branch
from
August 2, 2026 22:43
b6b616d to
ae8e0ee
Compare
jackluo923
marked this pull request as ready for review
August 2, 2026 22:47
jackluo923
force-pushed
the
feat/ca-trust-tests
branch
from
August 2, 2026 23:00
ae8e0ee to
7d0ae02
Compare
jackluo923
force-pushed
the
feat/ca-trust-tests
branch
from
August 2, 2026 23:24
7d0ae02 to
060c45c
Compare
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.
Description
Why
This repo has no shell tests, and neither project consuming the ca-trust library exercises it in CI —
y-scope/clp-plugin-presto-connectoronly sources the container half on local builds, andy-scope/clpnever passes a CA trust context. So a regression in this library has nowhere to be caught.What changed
45 assertions covering expired-certificate filtering against two committed fixtures, the empty-bundle and no-bundle paths, the container export matrix,
MAVEN_OPTSordering, command assembly with values containing spaces, quotes,$, and newlines, and the stripping of credentials from image labels and build logs.The suite runs on every CI platform, including macOS — whose
/bin/bashis 3.2. That caught a real one: the libraries used bash namerefs and failed outright on macOS, which #119 now fixes. #119 was green before these tests existed, because nothing exercised it.Two assertions are regressions for bugs found while integrating
y-scope/clp:CA_TRUST_JVMbeing passed by reference (so a caller that scoped the assignment to the call silently lost JVM trust), and a build-arg helper leaking a nonzero status to anerrexitcaller when its last variable was unset.Checklist
Validation performed
task testpasses.Every assertion was checked by reintroducing the bug it guards and confirming the suite fails and exits nonzero — a test that has never been seen to fail isn't evidence of anything.
That mattered twice here, and both lessons are baked into the harness:
( … ), where the failure counter can't propagate, so the suite reportedPASSED: 22/22while silently swallowing 10 assertions.grep -cneeds|| true. It exits 1 on zero matches, which undererrexitaborts the suite instead of failing the assertion — precisely when the regression is present. TheCA_TRUST_JVMtest hit exactly this and passed against a known-broken library until it was fixed.A shellcheck task is deliberately not included. The lint workflow only triggers on
**/*.py,**/*.pyi, and**/*.yaml, and shellcheck isn't installed in CI, so adding the task here would look like the shell libraries were linted while never actually running. Making it real means changing the workflow's path filters and installing the tool — a repo-wide policy change that should be proposed on its own, once this stack lands.