#!/usr/bin/make -f
# -*- makefile -*-

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
export PYBUILD_NAME=smstrade
export PYBUILD_BEFORE_TEST=cp -r {dir}/tests {build_dir}
export PYBUILD_TEST_ARGS=unset http_proxy ; unset https_proxy ; cd {build_dir} ; {interpreter} -m pytest
export PYBUILD_AFTER_TEST=rm -rf {build_dir}/tests
# do not install scripts for Python 2 they are provided by the Python 3 package
export PYBUILD_AFTER_INSTALL_python2=rm -rf {destdir}/usr/bin

override_dh_installchangelogs:
	dh_installchangelogs -i ChangeLog.rst

override_dh_auto_test:
	dh_auto_test -- --system=custom

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

