2019-02-18 19:33:58 +00:00
|
|
|
.PHONY: test test-build
|
2014-10-16 00:53:18 +00:00
|
|
|
|
2014-12-11 16:47:25 +00:00
|
|
|
# Do not pass in user flags to build tests.
|
|
|
|
unexport PYTHON_CFLAGS
|
|
|
|
unexport PYTHON_CONFIGURE_OPTS
|
|
|
|
|
2014-12-01 13:50:04 +00:00
|
|
|
test: bats
|
|
|
|
PATH="./bats/bin:$$PATH" test/run
|
|
|
|
cd plugins/python-build && $(PWD)/bats/bin/bats $${CI:+--tap} test
|
2014-10-16 00:53:18 +00:00
|
|
|
|
2019-04-08 14:54:12 +00:00
|
|
|
PYTHON_BUILD_ROOT := $(CURDIR)/plugins/python-build
|
|
|
|
PYTHON_BUILD_OPTS ?= --verbose
|
|
|
|
PYTHON_BUILD_VERSION ?= 3.8-dev
|
|
|
|
PYTHON_BUILD_TEST_PREFIX ?= $(PYTHON_BUILD_ROOT)/test/build/tmp/dist
|
|
|
|
|
|
|
|
test-build:
|
2019-04-08 15:07:13 +00:00
|
|
|
$(RM) -r $(PYTHON_BUILD_TEST_PREFIX)
|
2019-04-08 14:54:12 +00:00
|
|
|
$(PYTHON_BUILD_ROOT)/bin/python-build $(PYTHON_BUILD_OPTS) $(PYTHON_BUILD_VERSION) $(PYTHON_BUILD_TEST_PREFIX)
|
|
|
|
[ -e $(PYTHON_BUILD_TEST_PREFIX)/bin/python ]
|
|
|
|
$(PYTHON_BUILD_TEST_PREFIX)/bin/python -V
|
|
|
|
[ -e $(PYTHON_BUILD_TEST_PREFIX)/bin/pip ]
|
|
|
|
$(PYTHON_BUILD_TEST_PREFIX)/bin/pip -V
|
2019-02-18 19:33:58 +00:00
|
|
|
|
2014-12-01 13:50:04 +00:00
|
|
|
bats:
|
2019-02-18 19:33:58 +00:00
|
|
|
git clone --depth 1 https://github.com/bats-core/bats-core.git bats
|