From 4dbe5f837b8539e92555f04ded443522aca1a518 Mon Sep 17 00:00:00 2001 From: Sudhir Menon Date: Wed, 26 Jun 2024 15:27:18 +0530 Subject: [PATCH] Added gating.yaml and tests for python-cryptography Signed-off-by: Sudhir Menon --- gating.yaml | 7 +++++ tests/tests.yml | 68 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 75 insertions(+) create mode 100644 gating.yaml create mode 100644 tests/tests.yml diff --git a/gating.yaml b/gating.yaml new file mode 100644 index 0000000..122483d --- /dev/null +++ b/gating.yaml @@ -0,0 +1,7 @@ +# recipients: abokovoy, frenaud, kaleem, ftrivino, cheimes +--- !Policy +product_versions: + - rhel-10 +decision_context: osci_compose_gate +rules: + - !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional} diff --git a/tests/tests.yml b/tests/tests.yml new file mode 100644 index 0000000..f21d2cb --- /dev/null +++ b/tests/tests.yml @@ -0,0 +1,68 @@ +--- +# +# 1minutetip --buildroot rhel9 +# + +- hosts: localhost + tags: + - classic + roles: + - role: standard-test-source + + - role: standard-test-basic + required_packages: + - python3-cryptography + - python3-pytest + - python3-pytest-subtests + environment: + PYTHONPATH: "{{ srcdir }}/vectors" + OPENSSL_ENABLE_SHA1_SIGNATURES: "yes" + tests: + - remove_hypothesis: + # remove tests that depend on python3-hypothesis package + dir: "source" + run: rm -rf tests/hypothesis/ + - remove_iso8601: + # remove tests that depend on python3-iso8601 package + dir: "source" + run: rm -rf tests/test_fernet.py + - remove_scrypt: + # scrypt tests require more memory than available + dir: "source" + run: rm -f tests/hazmat/primitives/test_scrypt.py + - patch_conftest: + dir: "source" + run: "cat ../conftest-skipper.py >> tests/conftest.py" + # tests take some time, split up to avoid CI timeouts. + - unittests-basic: + dir: "source" + run: pytest-3 tests/test_*.py + - unittests-x509: + dir: "source" + run: pytest-3 tests/x509/ + - unittests-hazmat: + dir: "source" + run: pytest-3 -k 'not test_openssl_memleak' tests/hazmat/backends/ tests/hazmat/bindings/ + - unittests-primitives-aead: + dir: "source" + run: pytest-3 tests/hazmat/primitives/test_aead.py + - unittests-primitives-aes: + dir: "source" + run: >- + pytest-3 + tests/hazmat/primitives/test_aes.py::TestAESModeCBC + tests/hazmat/primitives/test_aes.py::TestAESModeCTR + tests/hazmat/primitives/test_aes_gcm.py::TestAESModeGCM + - unittests-primitives-a-e: + dir: "source" + run: >- + pytest-3 + tests/hazmat/primitives/test_arc4.py + tests/hazmat/primitives/test_asym_utils.py + tests/hazmat/primitives/test_[b-e]*.py + - unittests-primitives-f-z: + dir: "source" + run: >- + pytest-3 + tests/hazmat/primitives/test_[f-z]*.py + tests/hazmat/primitives/twofactor