From 4e4f6dcabf64b8a6b0e4fb57fc5b3602e1540bdf Mon Sep 17 00:00:00 2001 From: David Negreira Date: Thu, 18 Apr 2024 13:31:12 +0000 Subject: [PATCH] Add debian folder Add a debian folder to build avocado-framework as python3-avocado-framework package on Ubuntu. Currently the debian/copyright file needs a review, among other things to be improved before a final commit. This commit is meant to be reviewed by upstream maintainers of avocado-framework and work on improvements and pieces missing, so that we can squash and do a proper commit at a later stage. Signed-off-by: David Negreira --- debian/changelog | 5 +++++ debian/compat | 1 + debian/control | 15 ++++++++++++++ debian/copyright | 24 +++++++++++++++++++++++ debian/python3-avocado-framework.manpages | 1 + debian/rules | 17 ++++++++++++++++ examples/config/avocado-tests.conf | 4 ++++ 7 files changed, 67 insertions(+) create mode 100644 debian/changelog create mode 100644 debian/compat create mode 100644 debian/control create mode 100644 debian/copyright create mode 100644 debian/python3-avocado-framework.manpages create mode 100755 debian/rules create mode 100644 examples/config/avocado-tests.conf diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000000..239b2e003e --- /dev/null +++ b/debian/changelog @@ -0,0 +1,5 @@ +python3-avocado-framework (103.0ubuntu1) jammy; urgency=medium + + * Initial release. + + -- David Negreira Thu, 18 Apr 2024 12:53:10 +0000 diff --git a/debian/compat b/debian/compat new file mode 100644 index 0000000000..f599e28b8a --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +10 diff --git a/debian/control b/debian/control new file mode 100644 index 0000000000..46d71ba09e --- /dev/null +++ b/debian/control @@ -0,0 +1,15 @@ +Source: python3-avocado-framework +Section: python +Priority: optional +Maintainer: David Negreira +Build-Depends: debhelper (>=11~), dh-python, python3-all, python3-setuptools, python3-pip, python3-dev, python3-sphinx, python3-sphinx-rtd-theme +Standards-Version: 4.6.2 + +Package: python3-avocado-framework +Architecture: all +Homepage: https://github.com/avocado-framework/avocado +X-Python3-Version: >=3.7 +Depends: ${misc:Depends}, ${python3:Depends} +Description: Avocado is a set of tools and libraries to help with automated testing. + One can call it a test framework with benefits. + Native tests are written in Python and they follow the unittest pattern, but any executable can serve as a test. diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000000..3c1395d166 --- /dev/null +++ b/debian/copyright @@ -0,0 +1,24 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: Avocado Framework +Source: https://avocado-framework.github.io/ + +Files: * +Copyright: PLACEHOLDER for The Avocado Team +License: GPL-2+ + +Files: debian/* +Copyright: 2024, David Negreira +License: GPL-2+ + + +License: GPL-2+ + This is free software, licensed under: + . + The GNU General Public License, Version 2, June 1991 + . + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; version 2 dated June, 1991, or (at + your option) any later version. + On Debian systems, the complete text of version 2 of the GNU General + Public License can be found in '/usr/share/common-licenses/GPL-2'. diff --git a/debian/python3-avocado-framework.manpages b/debian/python3-avocado-framework.manpages new file mode 100644 index 0000000000..83fb7b471d --- /dev/null +++ b/debian/python3-avocado-framework.manpages @@ -0,0 +1 @@ +man/avocado.1 diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000000..da5c91a860 --- /dev/null +++ b/debian/rules @@ -0,0 +1,17 @@ +#!/usr/bin/make -f +DH_VERBOSE = 1 +export PYBUILD_NAME = avocado-framework-103 +export PYBUILD_INSTALL_ARGS=--install-layout=deb + +override_dh_auto_test: + + mkdir -p /build/etc/avocado/ + mkdir -p /build/avocado/data/job-results + mkdir -p /build/avocado/data/cache + cp examples/config/avocado-tests.conf /build/etc/avocado/avocado.conf + VIRTUAL_ENV="/build/" python3 setup.py test --select=unit +override_dh_installman: + python3 setup.py man + dh_installman +%: + dh $@ --with python3 --buildsystem=pybuild diff --git a/examples/config/avocado-tests.conf b/examples/config/avocado-tests.conf new file mode 100644 index 0000000000..47da9c72dd --- /dev/null +++ b/examples/config/avocado-tests.conf @@ -0,0 +1,4 @@ +[datadir.paths] +base_dir = /build/avocado/data +logs_dir = /build/avocado/data/job-results +cache_dirs = ['/build/avocado/data/cache']