Skip to content

Commit 671b240

Browse files
Merge pull request #25831 from Luap99/test-doc
update hack/bats to not PASS NOP env and update test README with more system test info
2 parents 1b9f78a + 85caf3f commit 671b240

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

hack/bats

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,6 @@ servers, because we can sudo *starting* the service but can't sudo
4444
stopping it: by the time the bats tests finish, the sudo timeout will
4545
have expired. We apologize for the inconvenience.)
4646
47-
$0 also passes through \$OCI_RUNTIME, should you need to test that.
48-
4947
Examples:
5048
5149
\$ $0 220:\"restart cleans up\"
@@ -137,7 +135,6 @@ if [[ "$TEST_ROOT" ]]; then
137135
sudo --preserve-env=PODMAN \
138136
--preserve-env=QUADLET \
139137
--preserve-env=PODMAN_TEST_DEBUG \
140-
--preserve-env=OCI_RUNTIME \
141138
--preserve-env=CONTAINERS_HELPER_BINARY_DIR \
142139
--preserve-env=PODMAN_ROOTLESS_USER \
143140
bats "${bats_opts[@]}" "${bats_filter[@]}" $TESTS

test/README.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,8 @@ The following environment variables are supported by the test setup:
9191
- `PODMAN_DB`: the database backend `sqlite` (default) or `boltdb`.
9292
- `PODMAN_TEST_IMAGE_CACHE_DIR`: path were the container images should be cached, defaults to `/tmp`.
9393

94+
Note: These variables are used by the integration tests (test/e2e) only not the system tests (test/system).
95+
9496
### Running a single file of integration tests
9597
You can run a single file of integration tests using the go test command:
9698

@@ -143,7 +145,16 @@ System tests are used for testing the *podman* CLI in the context of a complete
143145
requires that *podman*, all dependencies, and configurations are in place. The intention of
144146
system testing is to match as closely as possible with real-world user/developer use-cases
145147
and environments. The orchestration of the environments and tests is left to external
146-
tooling.
148+
tooling. To test a specific oci runtime it should be set in containers.conf.
149+
(Note, upstream only tests with crun, there is no guarantee that tests will pass with another
150+
runtime. We will accept patches to make the tests work with runc, e.g. mostly error message
151+
checks, but not other runtimes due to the high maintenance overhead.)
152+
153+
Only the following env vars are supported:
154+
- `PODMAN`: path to the podman binary, defaults to `podman` in $PATH.
155+
- `QUADLET`: path to the quadlet binary, defaults to `/usr/libexec/podman/quadlet`.
156+
- `PODMAN_TESTING`: path to the podman-testing binary, defaults to `../../bin/podman-testing` from the system test directory.
157+
Note, the binary is used for testing purposes only and is not expected to be shipped to end users.
147158

148159
System tests use Bash Automated Testing System (`bats`) as a testing framework.
149160
Install it via your package manager or get latest stable version

0 commit comments

Comments
 (0)