mirror of
https://github.com/microsoft/debugpy.git
synced 2025-12-23 08:48:12 +00:00
* Fix #811: new socket server to receive pid and port for subprocesses * Install test dependencies from test_requirements.txt on Travis * Multiproc support can't handle os.fork() as implemented. On Python 3.4+, use set_start_method('spawn') to ensure that multiprocessing module doesn't use fork. On lower versions, skip the test. * Restrict the multiprocessing test to Windows for now.
56 lines
1.5 KiB
Makefile
56 lines
1.5 KiB
Makefile
PYTHON ?= python3
|
|
|
|
|
|
.PHONY: help
|
|
help: ## Print help about available targets.
|
|
@grep -h -E '^[a-zA-Z0-9_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}'
|
|
|
|
.PHONY: depends
|
|
depends:
|
|
$(PYTHON) -m pip install --upgrade pip
|
|
$(PYTHON) -m pip install setuptools
|
|
$(PYTHON) -m pip install flake8_formatter_junit_xml
|
|
$(PYTHON) -m pip install unittest-xml-reporting
|
|
$(PYTHON) -m pip install -r test_requirements.txt
|
|
|
|
.PHONY: lint
|
|
lint: ## Lint the Python source code.
|
|
#$(PYTHON) -m flake8 --ignore E24,E121,E123,E125,E126,E221,E226,E266,E704,E265,E501 --exclude ptvsd/pydevd $(CURDIR)
|
|
$(PYTHON) -m tests --lint-only
|
|
|
|
.PHONY: test
|
|
test: ## Run the test suite.
|
|
$(PYTHON) -m tests -v --full
|
|
|
|
.PHONY: test-quick
|
|
test-quick:
|
|
$(PYTHON) -m tests -v --quick
|
|
|
|
.PHONY: coverage
|
|
coverage: ## Check line coverage.
|
|
#$(PYTHON) -m coverage run --include 'ptvsd/*.py' --omit 'ptvsd/pydevd/*.py' -m tests
|
|
$(PYTHON) -m tests -v --full --coverage
|
|
|
|
.PHONY: check-schemafile
|
|
check-schemafile: ## Validate the vendored DAP schema file.
|
|
$(PYTHON) -m debugger_protocol.schema check
|
|
|
|
|
|
##################################
|
|
# CI
|
|
|
|
.PHONY: ci-lint
|
|
ci-lint: depends lint
|
|
|
|
.PHONY: ci-test
|
|
ci-test: depends
|
|
# For now we use --quickpy2.
|
|
$(PYTHON) -m tests -v --full --no-network --quick-py2
|
|
$(PYTHON) setup.py test
|
|
|
|
.PHONY: ci-coverage
|
|
ci-coverage: depends
|
|
$(PYTHON) -m tests -v --full --coverage --no-network
|
|
|
|
.PHONY: ci-check-schemafile
|
|
ci-check-schemafile: check-schemafile
|