File: smoke-python3

package info (click to toggle)
python-lockfile 1%3A0.12.2-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 292 kB
  • sloc: python: 697; makefile: 76; sh: 19
file content (51 lines) | stat: -rwxr-xr-x 1,410 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#! /bin/bash
#
# debian/tests/smoke-python3
# Part of Debian ‘python-lockfile’ package.
#
# This is free software, and you are welcome to redistribute it under
# certain conditions; see the end of this file for copyright
# information, grant of license, and disclaimer of warranty.

# Smoke test for package in Python 3 environments.

set -o errexit
set -o errtrace
set -o nounset

DISTRIBUTION_NAME=lockfile
MODULE_NAMES=(
        lockfile
        )

program_dir="$(dirname "$(realpath --strip "$0")")"

# Use a working directory away from the source package root,
# so that Python imports will not find the local source package.
working_dir="$program_dir"
cd "$working_dir"

test_opts="--distribution=$DISTRIBUTION_NAME"
for mod in ${MODULE_NAMES[@]} ; do
    # Accumulate the module names.
    test_opts="$test_opts --module=$mod"
done

for py in $(py3versions --supported) ; do
    printf "Python command: %s\n" $py
    $py -m package_smoke_test $test_opts
    printf "\n"
done


# Copyright © 2016–2024 Ben Finney <bignose@debian.org>
# This is free software: you may copy, modify, and/or distribute this work
# under the terms of the GNU General Public License as published by the
# Free Software Foundation; version 3 of that license or any later version.
# No warranty expressed or implied.

# Local variables:
# coding: utf-8
# mode: shell-script
# End:
# vim: fileencoding=utf-8 filetype=sh :