From deffb32fe4f024bdaf76a9967d3003d11359474e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20=C5=A0pl=C3=ADchal?= Date: Mon, 26 Oct 2020 13:23:31 +0100 Subject: [PATCH] Enable relevant tests from the shared shell repo This pull request enables tests in the Fedora CI using `tmt` which also allows to easily execute and debug tests from your laptop: Run tests directly on your localhost: sudo dnf install -y tmt tmt run --all provision --how local Run tests in a virtual machine: sudo dnf install -y tmt-provision-virtual tmt run Check the documentation to learn more about the tool: https://docs.fedoraproject.org/en-US/ci/tmt/ --- .fmf/version | 1 + plans/shell.fmf | 14 ++++++++++++++ tests/tests.yml | 36 ------------------------------------ 3 files changed, 15 insertions(+), 36 deletions(-) create mode 100644 .fmf/version create mode 100644 plans/shell.fmf delete mode 100644 tests/tests.yml diff --git a/.fmf/version b/.fmf/version new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/.fmf/version @@ -0,0 +1 @@ +1 diff --git a/plans/shell.fmf b/plans/shell.fmf new file mode 100644 index 0000000..6c123e4 --- /dev/null +++ b/plans/shell.fmf @@ -0,0 +1,14 @@ +summary: + Run relevant tests from the shell tests repository +discover: + how: fmf + url: https://src.fedoraproject.org/tests/shell + filter: component:ksh +prepare: + how: install + package: ksh +execute: + how: tmt +environment: + PACKAGES: ksh + SH_BIN: ksh diff --git a/tests/tests.yml b/tests/tests.yml deleted file mode 100644 index e483864..0000000 --- a/tests/tests.yml +++ /dev/null @@ -1,36 +0,0 @@ ---- - -# Tests that run in classic context -- hosts: localhost - roles: - - role: standard-test-beakerlib - tags: - - classic - repositories: - - repo: "https://src.fedoraproject.org/tests/shell.git" - dest: "shell" - fmf_filter: "tier: 1, 2 & tags: classic" - environment: - PACKAGES: ksh - SH_BIN: ksh - required_packages: - - ksh - - expect # login requires expect - - which # smoke requires which - -# Tests that run in container -- hosts: localhost - roles: - - role: standard-test-beakerlib - tags: - - container - repositories: - - repo: "https://src.fedoraproject.org/tests/shell.git" - dest: "shell" - fmf_filter: "tier: 1, 2 & tags: container, atomic" - environment: - PACKAGES: ksh - SH_BIN: ksh - required_packages: - - ksh - - which # smoke requires which