You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildstream.apache.org by tv...@apache.org on 2022/04/05 10:04:38 UTC
[buildstream-plugins] 23/49: tox.ini: Adding initial tox.ini
This is an automated email from the ASF dual-hosted git repository.
tvb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/buildstream-plugins.git
commit 8e16746b2df0a0a1e793860682b02c2f128c5e82
Author: Tristan van Berkom <tr...@codethink.co.uk>
AuthorDate: Sat Mar 19 15:46:21 2022 +0900
tox.ini: Adding initial tox.ini
For now only formatting and lint checks pass
---
tox.ini | 104 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 104 insertions(+)
diff --git a/tox.ini b/tox.ini
new file mode 100644
index 0000000..44e0d0c
--- /dev/null
+++ b/tox.ini
@@ -0,0 +1,104 @@
+#
+# Tox global configuration
+#
+[tox]
+envlist = py{37,38,39,310}-{bst-fixed,bst-master}
+skip_missing_interpreters = true
+
+#
+# Defaults for all environments
+#
+# Anything specified here is inherited by the sections
+#
+[testenv]
+commands =
+ bst --version
+ pytest --basetemp {envtmpdir} {posargs}
+deps =
+ -rrequirements/test-requirements.txt
+ -rrequirements/plugin-requirements.txt
+ git+https://github.com/apache/buildstream@{env:BST_VERSION}
+
+passenv =
+ ARTIFACT_CACHE_SERVICE
+ BST_FORCE_BACKEND
+ BST_FORCE_SANDBOX
+ GI_TYPELIB_PATH
+ INTEGRATION_CACHE
+ http_proxy
+ HTTP_PROXY
+ https_proxy
+ HTTPS_PROXY
+ no_proxy
+ NO_PROXY
+ PYTEST_*
+ REMOTE_EXECUTION_SERVICE
+ SOURCE_CACHE_SERVICE
+ SSL_CERT_FILE
+
+#
+# These keys are not inherited by any other sections
+#
+setenv =
+ py{37,38,39,310}: XDG_CACHE_HOME = {envtmpdir}/cache
+ py{37,38,39,310}: XDG_CONFIG_HOME = {envtmpdir}/config
+ py{37,38,39,310}: XDG_DATA_HOME = {envtmpdir}/share
+ !master: BST_VERSION = 10be3784afa924d5af63958fea9354d0323eadad
+ master: BST_VERSION = master
+
+whitelist_externals =
+ py{37,38,39,310}:
+ mv
+ mkdir
+
+#
+# Code formatters
+#
+[testenv:format]
+skip_install = True
+deps =
+ black==19.10b0
+commands =
+ black {posargs: src tests setup.py}
+
+#
+# Code format checkers
+#
+[testenv:format-check]
+skip_install = True
+deps =
+ black==19.10b0
+commands =
+ black --check --diff {posargs: src tests setup.py}
+
+#
+# Running linters
+#
+[testenv:lint]
+commands_pre =
+ # Build C extensions to allow Pylint to analyse them
+ {envpython} setup.py build_ext --inplace
+
+commands =
+ pylint {posargs: buildstream_plugins tests setup.py}
+
+#
+# Building documentation
+#
+[testenv:docs]
+commands =
+ make -C doc
+# sphinx_rtd_theme < 0.4.2 breaks search functionality for Sphinx >= 1.8
+deps =
+ sphinx >= 1.8.5
+ sphinx_rtd_theme >= 0.4.2
+ -rrequirements/plugin-requirements.txt
+ git+https://github.com/apache/buildstream@{env:BST_VERSION}
+passenv =
+ BST_FORCE_SESSION_REBUILD
+ BST_SOURCE_CACHE
+ HOME
+ LANG
+ LC_ALL
+whitelist_externals =
+ make