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
|
#!/bin/sh
# Run all self tests.
# (C) 2010 Canonical Ltd.
# Author: Martin Pitt <martin.pitt@ubuntu.com>
#
# 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; either version 2 of the License, or (at your
# option) any later version. See http://www.gnu.org/copyleft/gpl.html for
# the full text of the license.
set -e
set -x
type ${PYTHON:=python}
for checker in pyflakes py3flakes; do
if type $checker >/dev/null 2>&1; then
$checker lib/*.py import test/import
fi
done
if type pep8 >/dev/null 2>&1; then
pep8 --ignore=E501,E402 lib/*.py import test/import
fi
# unit tests
$PYTHON -tt lib/localeinfo.py
$PYTHON -tt lib/macros.py -v
$PYTHON -tt lib/pkg_classify.py -v
$PYTHON -tt lib/static_translations.py
$PYTHON -tt lib/makepkg.py -v
# integration tests
$PYTHON test/import -v
|