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

genpolicy: add crate-scoped integration test #309

Draft
wants to merge 1 commit into
base: msft-main
Choose a base branch
from

Conversation

Redent0r
Copy link

Provides a test runner that generates a policy and validates it with canned requests. The initial set of test cases is mostly for illustration and will be expanded incrementally.

In order to enable both cross-compilation on Ubuntu test runners as well as native compilation on the Alpine tools builder, it is easiest to switch to the vendored openssl-src variant. This builds OpenSSL from source, which depends on Perl at build time.

Adding the test to the Makefile makes it execute in CI, on a variety of architectures. Building on ppc64le requires a newer version of the libz-ng-sys crate.

Fixes: kata-containers#10061

Merge Checklist
  • Followed patch format from upstream recommendation: https://github.com/kata-containers/community/blob/main/CONTRIBUTING.md#patch-format
    • Included a single commit in a given PR - at least unless there are related commits and each makes sense as a change on its own.
  • Aware about the PR to be merged using "create a merge commit" rather than "squash and merge" (or similar)
  • The upstream/missing label (or upstream/not-needed) has been set on the PR.
Summary

todo:

Test Methodology

Provides a test runner that generates a policy and validates it
with canned requests. The initial set of test cases is mostly for
illustration and will be expanded incrementally.

In order to enable both cross-compilation on Ubuntu test runners as well
as native compilation on the Alpine tools builder, it is easiest to
switch to the vendored openssl-src variant. This builds OpenSSL from
source, which depends on Perl at build time.

Adding the test to the Makefile makes it execute in CI, on a variety of
architectures. Building on ppc64le requires a newer version of the
libz-ng-sys crate.

Fixes: kata-containers#10061

Signed-off-by: Markus Rudy <mr@edgeless.systems>
@Redent0r Redent0r added the upstream/merged PRs that have been merged upstream label Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
upstream/merged PRs that have been merged upstream
Projects
None yet
Development

Successfully merging this pull request may close these issues.

genpolicy: add crate-scoped testing
2 participants