#!/usr/bin/make -f

# output every command that modifies files on the build system.
#export DH_VERBOSE = 1

export PYBUILD_NAME=apispec-webframeworks
PY_VERSIONS=$$(py3versions -r 2>/dev/null | sed s/python//g)

%:
	dh $@ --with python3 --buildsystem=pybuild

override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	for py in $(PY_VERSIONS); do cp -r $(CURDIR)/src/apispec_webframeworks.egg-info $(CURDIR)/.pybuild/cpython3_$${py}_apispec-webframeworks/build/; done
	dh_auto_test
	for py in $(PY_VERSIONS); do rm -rf $(CURDIR)/.pybuild/cpython3_$${py}_apispec-webframeworks/build/apispec_webframeworks.egg-info; done
endif
