#!/usr/bin/make -f
export DH_VERBOSE = 1
export PYBUILD_NAME=errbot
#export PYBUILD_SYSTEM=distutils
export PYBUILD_DESTDIR_python3=debian/python3-errbot/
export PYBUILD_DESTDIR_python3-dbg=debian/python3-errbot-dbg/

export PYBUILD_TEST_ARGS=-k "not test_broken_plugin and \
	not test_backup and \
	not test_plugin_cycle and \
	not test_entrypoint_paths and \
	not test_check_dependencies_requirements_file_all_installed"

export PYBUILD_BEFORE_TEST=rm -f {dir}/tests/backend_tests/slack_test.py

%:
	dh $@ --buildsystem=pybuild

override_dh_install:
	python3 setup.py install --root=debian/errbot/ --install-layout=deb
	dh_install

override_dh_auto_test:
	localehelper LANG=en_US.UTF-8 dh_auto_test

override_dh_installsystemd:
	dh_installsystemd errbot@.service

override_dh_installinit:
	dh_installinit --no-start