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/tests.fmf b/plans/tests.fmf new file mode 100644 index 0000000..f8d7183 --- /dev/null +++ b/plans/tests.fmf @@ -0,0 +1,9 @@ +summary: Tests +discover: + how: fmf + dist-git-source: true +prepare: + how: feature + crb: enabled +execute: + how: tmt diff --git a/tests/tests.yml b/tests/tests.yml deleted file mode 100644 index fc72442..0000000 --- a/tests/tests.yml +++ /dev/null @@ -1,27 +0,0 @@ ---- -- hosts: localhost - tags: - - classic - pre_tasks: - - name: Enable CRB for python3-pytest on 1minutetip - ini_file: - path: /etc/yum.repos.d/rhel.repo - section: rhel-CRB - option: enabled - value: "1" - create: no - ignore_errors: yes - roles: - - role: standard-test-source - required_packages: - - git - - role: standard-test-basic - required_packages: - - python3-kdcproxy - - python3-pytest - tests: - - unittests: - dir: "source" - run: >- - rm -rf kdcproxy* && - python3 -m pytest diff --git a/tests/unittests/main.fmf b/tests/unittests/main.fmf new file mode 100644 index 0000000..599efca --- /dev/null +++ b/tests/unittests/main.fmf @@ -0,0 +1,13 @@ +summary: Unit tests +component: +- python-kdcproxy +require: +- python3-kdcproxy +- python3-pytest +test: | + setuppy_path="$(find "$TMT_SOURCE_DIR" -type f -name setup.py)" + src_path="$(dirname "$setuppy_path")" + pushd "$src_path" + python3 -m pytest +duration: 15m +enabled: true