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

#export DH_VERBOSE = 1

export PYBUILD_NAME=strawberry
export PYBUILD_BEFORE_TEST=cp -r {dir}/docs {build_dir}
export PYBUILD_AFTER_TEST=rm -rf {build_dir}/docs
export PYBUILD_AFTER_INSTALL=find {destdir}{install_dir}/strawberry -type f -name "LICENSE" | xargs -r rm -vrf
export DJANGO_SETTINGS_MODULE=tests.django.django_settings

export PYBUILD_TEST_ARGS=\
 --ignore=tests/cli/test_locate_definition.py \
 --ignore=tests/http/test_graphql_ide.py \
 --ignore=tests/http/test_upload.py \
 --ignore=tests/litestar/test_context.py \
 --ignore=tests/litestar/test_response_headers.py \
 --ignore=tests/litestar/test_response_status.py \
 --ignore=tests/sanic/test_file_upload.py \
 -k ' \
     not test_fetch_data_from_db \
 and not test_lazy_types_loaded_from_same_module \
 ' \
 ${NULL}

%:
	dh $@ --buildsystem=pybuild

override_dh_clean:
	dh_clean
	rm -rf .mypy_cache
