1
0
mirror of https://github.com/scrapy/scrapy.git synced 2025-02-11 15:31:32 +00:00
scrapy/tox.ini

164 lines
3.5 KiB
INI
Raw Normal View History

2017-10-28 16:48:41 +05:30
# Tox (https://tox.readthedocs.io/) is a tool for running tests
# in multiple virtualenvs. This configuration file will run the
# test suite on all supported python versions. To use it, "pip install tox"
# and then run "tox" from this directory.
[tox]
envlist = security,flake8,py
minversion = 1.7.0
[testenv]
deps =
-ctests/constraints.txt
2019-10-31 14:46:02 +05:00
-rtests/requirements-py3.txt
# Extras
2020-05-15 22:50:54 +03:00
boto3>=1.13.0
botocore>=1.4.87
2020-08-22 04:33:35 -03:00
Pillow>=4.0.0
passenv =
2016-02-15 17:50:47 +03:00
S3_TEST_FILE_URI
AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY
2017-09-13 16:24:04 +09:00
GCS_TEST_FILE_URI
GCS_PROJECT_ID
#allow tox virtualenv to upgrade pip/wheel/setuptools
download = true
commands =
2019-11-14 15:42:34 +01:00
py.test --cov=scrapy --cov-report= {posargs:--durations=10 docs scrapy tests}
2020-09-29 00:27:39 +07:00
install_command =
pip install --use-feature=2020-resolver {opts} {packages}
2020-06-18 13:52:04 -03:00
[testenv:typing]
basepython = python3
deps =
mypy==0.780
commands =
mypy {posargs: scrapy tests}
[testenv:security]
basepython = python3
deps =
bandit
commands =
bandit -r -c .bandit.yml {posargs:scrapy}
2013-11-19 20:15:15 -02:00
[testenv:flake8]
basepython = python3
deps =
{[testenv]deps}
pytest-flake8
commands =
py.test --flake8 {posargs:docs scrapy tests}
2019-12-18 15:43:40 +01:00
[testenv:pylint]
basepython = python3
deps =
{[testenv]deps}
# Optional dependencies
boto
reppy
robotexclusionrulesparser
# Test dependencies
pylint
commands =
pylint conftest.py docs extras scrapy setup.py tests
2020-07-02 20:10:08 +02:00
[pinned]
deps =
-ctests/constraints.txt
2020-10-01 19:59:23 +07:00
#using cryptography-2.3.1 to solve dependencies conflict on pip20.2>=
cryptography==2.3.1
cssselect==0.9.1
itemadapter==0.1.0
parsel==1.5.0
2019-09-09 08:12:32 +00:00
Protego==0.1.15
!pypy3: PyDispatcher==2.0.5
2020-10-01 15:47:19 +07:00
#using pyOpenSSL<18.1 to solve dependencies conflict with mitmproxy on pip20.2>=
pyOpenSSL==18.0.0
queuelib==1.4.2
service_identity==16.0.0
Twisted==20.3.0
w3lib==1.17.0
#zope.interface==5.1.2 to resolve conflict with Twisted==20.3.0
2020-10-06 19:51:42 +07:00
zope.interface==5.1.2
-rtests/requirements-py3.txt
# Extras
botocore==1.4.87
google-cloud-storage==1.29.0
2020-08-22 04:33:35 -03:00
Pillow==4.0.0
2020-07-02 20:10:08 +02:00
[testenv:pinned]
deps =
{[pinned]deps}
lxml==3.5.0
2020-07-02 20:10:08 +02:00
[testenv:windows-pinned]
basepython = python3
deps =
{[pinned]deps}
# First lxml version that includes a Windows wheel for Python 3.6, so we do
2020-07-02 20:10:08 +02:00
# not need to build lxml from sources in a CI Windows job:
lxml==3.8.0
[testenv:extra-deps]
2019-11-07 14:05:01 +01:00
deps =
{[testenv]deps}
reppy
robotexclusionrulesparser
2019-11-07 14:05:01 +01:00
[testenv:asyncio]
commands =
{[testenv]commands} --reactor=asyncio
[testenv:asyncio-pinned]
deps = {[testenv:pinned]deps}
commands = {[testenv:asyncio]commands}
[testenv:pypy3]
basepython = pypy3
deps =
{[testenv]deps}
lxml==4.0.0
commands =
py.test {posargs:--durations=10 docs scrapy tests}
[testenv:pypy3-pinned]
basepython = {[testenv:pypy3]basepython}
deps =
{[pinned]deps}
lxml==4.0.0
PyPyDispatcher==2.1.0
commands = {[testenv:pypy3]commands}
[docs]
2014-04-09 18:46:01 -03:00
changedir = docs
deps =
2017-03-20 22:21:08 +05:30
-rdocs/requirements.txt
2020-04-16 14:48:38 +02:00
setenv =
READTHEDOCS_PROJECT=scrapy
READTHEDOCS_VERSION=master
[testenv:docs]
2019-12-18 15:50:49 +01:00
basepython = python3
changedir = {[docs]changedir}
deps = {[docs]deps}
2020-04-16 14:48:38 +02:00
setenv = {[docs]setenv}
2014-04-09 18:46:01 -03:00
commands =
sphinx-build -W -b html . {envtmpdir}/html
[testenv:docs-coverage]
2019-12-18 15:50:49 +01:00
basepython = python3
changedir = {[docs]changedir}
deps = {[docs]deps}
2020-04-16 14:48:38 +02:00
setenv = {[docs]setenv}
commands =
sphinx-build -b coverage . {envtmpdir}/coverage
[testenv:docs-links]
2019-12-18 15:50:49 +01:00
basepython = python3
changedir = {[docs]changedir}
deps = {[docs]deps}
2020-04-16 14:48:38 +02:00
setenv = {[docs]setenv}
commands =
sphinx-build -W -b linkcheck . {envtmpdir}/linkcheck