tox.ini
author Sylvain Thénault <sylvain.thenault@logilab.fr>
Fri, 03 Nov 2017 11:44:31 +0100
changeset 2862 f434324b01f0
parent 2388 b8fc498d0227
child 2889 cfcfe7afe41a
permissions -rw-r--r--
[hooks] Add condition on rql syncing mime type and format id from file category Add restriction in each EXISTS clause to ensure the specified eids are actually a generic category (top level concept) or a file extension (1st level concept). This will avoid errors catched by test added in next commit with a different default vocabulary for mime types / format ids. A monkey-patch has to be backported to allow using computed relation in write query, which is not implemented in cw < 3.25.4 Related to #39322647

[tox]
envlist = py27, flake8, check-manifest

[tox:jenkins]
envlist = py27, flake8-jenkins, check-manifest


[testenv]
sitepackages = True
deps =
  -rdev-requirements.txt
commands = {envpython} -m pytest {posargs:{toxinidir}/test}

[pytest]
python_files = *test_*.py


[testenv:check-manifest]
skip_install = true
deps =
  check-manifest
commands =
  {envpython} -m check_manifest {toxinidir}


[testenv:flake8]
skip_install = true
whitelist_externals =
  flake8
deps =
  flake8
commands = flake8 {posargs:{toxinidir}}

[testenv:flake8-jenkins]
skip_install = true
whitelist_externals =
  flake8
deps =
  flake8
commands = flake8 --exit-zero --show-source --output-file=code_quality.log {toxinidir}

[flake8]
format = pylint
ignore = W503
max-line-length = 100
max-complexity = 12
exclude = doc/conf.py,cubicweb_seda/uiprops.py,cubicweb_seda/entities/generated.py,cubicweb_seda/views/uicfg.py,cubicweb_seda/schema/seda2.py,cubicweb_seda/migration/*,test/data/*,.tox/*


[testenv:make]
whitelist_externals =
  make
setenv =
    PYTHONHASHSEED = 0
commands = make -C cubicweb_seda {posargs}


[testenv:doc]
changedir = doc
whitelist_externals =
  sphinx-build
deps =
  sphinx
commands = sphinx-build -b html -d {envtmpdir}/doctrees .  {envtmpdir}/html