#!/usr/bin/make -f
# Keep test caches outside the pybuild tree copied into the binary package.
export HYPOTHESIS_STORAGE_DIRECTORY = $(CURDIR)/.hypothesis

# The anchor check uses git ls-files and requires a Git checkout.
PYBUILD_TEST_ARGS = -k "not test_v14_constants_blob_unpickles_into_shim and not test_v14_pickle_restores_and_parses_warning_free and not test_v14_humanname_blob_unpickles and not test_no_old_design_doc_anchors" $(PYBUILD_TEST_IGNORE) tests

ifeq ($(PYBUILD_AUTOPKGTEST),1)
# Exclude source-checkout checks and expensive property grids only here;
# build-time testing still runs them. Do not copy parser sources into autopkgtest.
PYBUILD_TEST_IGNORE = --ignore=tests/v2/test_differential.py \
	--ignore=tests/v2/test_doc_citations.py \
	--ignore=tests/v2/test_local_agreement.py \
	--ignore=tests/v2/test_local_corpora.py \
	--ignore=tests/v2/test_measure.py \
	--ignore=tests/v2/test_vocab.py \
	--ignore=tests/v2/test_word_report.py \
	--ignore=tests/v2/test_properties.py
endif

export PYBUILD_TEST_ARGS

%:
	dh $@ --buildsystem=pybuild
