#!/usr/bin/make -f #export DH_VERBOSE=1 # auth_token middleware now requires access to HOME, otherwise # test suite cause FTBFS. See (LP: #1031022) export HOME="$(CURDIR)/debian/tests/" # This is to avoid git clone of keystoneclient when running unit tests. # See https://review.openstack.org/122768/ export KSCTEST_PATH=/usr/lib/python2.7/dist-packages/keystoneclient include /usr/share/openstack-pkg-tools/pkgos.make export OSLO_PACKAGE_VERSION=$(shell dpkg-parsechangelog | grep Version: | cut -d' ' -f2 | sed -e 's/^[[:digit:]]*://' -e 's/[-].*//' -e 's/~/.0/' | head -n 1) %: dh $@ --buildsystem=python_distutils --with python2,sphinxdoc,systemd override_dh_auto_test: ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS))) @echo "===> Running tests" mkdir -p $(CURDIR)/keystone/tests/tmp patch -p1 -R Testing with python$$i (python$$PYMAJOR)" ; \ rm -rf .testrepository ; \ testr-python$$PYMAJOR init ; \ TEMP_REZ=`mktemp -t` ; \ PYTHONPATH=$(CURDIR) PYTHON=python$$i testr-python$$PYMAJOR run --subunit 'keystone\.tests\.unit.*' | tee $$TEMP_REZ | subunit2pyunit ; \ cat $$TEMP_REZ | subunit-filter -s --no-passthrough | subunit-stats ; \ rm -f $$TEMP_REZ ; \ testr-python$$PYMAJOR slowest ; \ done patch -p1