#! /usr/bin/make -f

export PYBUILD_NAME=sqlmodel
export DH_VERBOSE=1

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

override_dh_auto_clean:
	PYBUILD_SYSTEM=custom PYBUILD_CLEAN_ARGS="{interpreter} debian/setup.py clean" dh_auto_clean

override_dh_auto_build:
	PYBUILD_SYSTEM=custom PYBUILD_BUILD_ARGS="{interpreter} debian/setup.py build" dh_auto_build

override_dh_auto_install:
	PYBUILD_SYSTEM=custom PYBUILD_INSTALL_ARGS="{interpreter} debian/setup.py install --root={destdir} --install-layout=deb" dh_auto_install

override_dh_auto_configure:
	echo "pass"

override_dh_auto_test:
	# test_create_db_and_table: converage cant find docs_src so this test fails
	PYBUILD_SYSTEM=custom PYBUILD_TEST_ARGS="PYTHONPATH=$(CURDIR) {interpreter} -m pytest -k 'not test_create_db_and_table' " dh_auto_test
