#!/usr/bin/make -f

#export DH_VERBOSE = 1

export PYBUILD_NAME=blackboxprotobuf

export PYBUILD_DIR = lib/

%:
	dh $@ --buildsystem=pybuild

override_dh_auto_test:
	find .pybuild -path "*/tests/payloads/Test.proto" \
		-exec sh -c 'protoc --python_out=$$(dirname $$(dirname {}))/py_test {}' \;

	PYBUILD_TEST_ARGS="-k 'not test_proto_import_examples'" \
		dh_auto_test

override_dh_auto_clean:
	dh_auto_clean
	rm -rf .mypy_cache .pytest_cache
