From 625ffc8163d49466cd3e703715c9b28c82d6c8c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20=C5=A0pl=C3=ADchal?= Date: Thu, 1 Dec 2022 12:54:28 +0100 Subject: [PATCH] Enable a `tmt` smoke test for container provision Recently the basic `podman` functionality has been broken several times. In order to ensure that the `tmt` container provision plugin works fine let's enable a simple smoke test. Related: #2150283 --- .fmf/version | 1 + plans/basic.fmf | 5 +++++ tests/main.fmf | 2 ++ tests/smoke.fmf | 2 ++ tests/tmt.fmf | 8 ++++++++ 5 files changed, 18 insertions(+) create mode 100644 .fmf/version create mode 100644 plans/basic.fmf create mode 100644 tests/main.fmf create mode 100644 tests/smoke.fmf create mode 100644 tests/tmt.fmf 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/basic.fmf b/plans/basic.fmf new file mode 100644 index 0000000..c43473a --- /dev/null +++ b/plans/basic.fmf @@ -0,0 +1,5 @@ +summary: Check basic functionality +discover: + how: fmf +execute: + how: tmt diff --git a/tests/main.fmf b/tests/main.fmf new file mode 100644 index 0000000..765b81d --- /dev/null +++ b/tests/main.fmf @@ -0,0 +1,2 @@ +require: + - podman diff --git a/tests/smoke.fmf b/tests/smoke.fmf new file mode 100644 index 0000000..97f2de4 --- /dev/null +++ b/tests/smoke.fmf @@ -0,0 +1,2 @@ +summary: Execute a simple command +test: podman run -t --rm fedora cat /etc/os-release | grep 'Fedora Linux' diff --git a/tests/tmt.fmf b/tests/tmt.fmf new file mode 100644 index 0000000..cd19cfe --- /dev/null +++ b/tests/tmt.fmf @@ -0,0 +1,8 @@ +summary: Make sure that container provision works +require: + - tmt-provision-container +test: + tmt run --verbose --remove + provision --how container --image fedora + login --command 'cat /etc/os-release' + finish