tox.ini 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. [tox]
  2. envlist = flake8,py27,py34,py35,gae,cover
  3. [testenv]
  4. basedeps = mock>=1.3.0
  5. pycrypto>=2.6
  6. cryptography>=1.0
  7. pyopenssl>=0.14
  8. webtest
  9. pytest
  10. flask
  11. sqlalchemy
  12. fasteners
  13. deps = {[testenv]basedeps}
  14. django
  15. keyring
  16. jsonpickle
  17. setenv =
  18. pypy: with_gmp=no
  19. DJANGO_SETTINGS_MODULE=tests.contrib.django_util.settings
  20. commands =
  21. py.test {posargs}
  22. [coverbase]
  23. basepython = python2.7
  24. commands =
  25. py.test \
  26. --cov=oauth2client \
  27. --cov=tests
  28. py.test \
  29. --cov=oauth2client \
  30. --cov=tests \
  31. --cov-append \
  32. --gae-sdk={env:GAE_PYTHONPATH:} \
  33. tests/contrib/appengine
  34. deps = {[testenv]deps}
  35. coverage
  36. pytest-cov
  37. [testenv:cover]
  38. basepython = {[coverbase]basepython}
  39. commands =
  40. {[coverbase]commands}
  41. coverage report --show-missing --fail-under=100
  42. deps =
  43. {[coverbase]deps}
  44. [testenv:docs]
  45. basepython = python2.7
  46. deps =
  47. {[testenv:cover]deps}
  48. python-gflags
  49. pyyaml
  50. sphinx>=1.3b2
  51. sphinx-rtd-theme
  52. webapp2
  53. commands = {toxinidir}/scripts/build_docs.sh
  54. [testenv:gae]
  55. basepython = python2.7
  56. deps = {[testenv]basedeps}
  57. commands =
  58. py.test --gae-sdk={env:GAE_PYTHONPATH:} tests/contrib/appengine
  59. [testenv:system-tests]
  60. basepython =
  61. python2.7
  62. commands =
  63. {toxinidir}/scripts/run_system_tests.sh
  64. deps =
  65. pycrypto>=2.6
  66. cryptography>=1.0
  67. pyopenssl>=0.14
  68. passenv = GOOGLE_* OAUTH2CLIENT_* TRAVIS* encrypted_*
  69. [testenv:system-tests3]
  70. basepython =
  71. python3.4
  72. commands =
  73. {toxinidir}/scripts/run_system_tests.sh
  74. deps =
  75. pycrypto>=2.6
  76. cryptography>=1.0
  77. pyopenssl>=0.14
  78. passenv = {[testenv:system-tests]passenv}
  79. [testenv:gce-system-tests]
  80. basepython =
  81. python2.7
  82. commands =
  83. python {toxinidir}/scripts/run_gce_system_tests.py
  84. deps =
  85. pycrypto>=2.6
  86. passenv = {[testenv:system-tests]passenv}
  87. [testenv:flake8]
  88. commands = flake8 --import-order-style google {posargs}
  89. deps =
  90. flake8-putty
  91. flake8-import-order
  92. [flake8]
  93. exclude = .tox,.git,./*.egg,build,.cache,env,__pycache__
  94. application-import-names = oauth2client, tests
  95. putty-ignore =
  96. # E402 module level import not at top of file
  97. # This file has needed configurations defined before import
  98. docs/conf.py : E402
  99. # E501 line too long
  100. # Ignore lines over 80 chars that include "http:" or "https:"
  101. /http:/ : E501
  102. /https:/ : E501
  103. # E722 do not use bare except
  104. # Existing sloppy usages.
  105. oauth2client/crypt.py : E722
  106. oauth2client/contrib/multiprocess_file_storage.py : E722