Commit Graph

12 Commits

Author SHA1 Message Date
Kefu Chai
da40d84640 cmake: temporarily disable py3 test
py3 tries to import all python modules to ensure that they are
python3 compatible. but the installation fails on jenkins test node:

  Resolved https://github.com/ceph/teuthology.git to commit 4da97cf64e542f347ec47b7bdbe5eca99759f9b7
  Installing build dependencies: started
  error: subprocess-exited-with-error

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2022-12-09 01:07:19 +08:00
Sebastian Wagner
c6779fdf13
qa/tox.ini: check for dead symlinks
IMO the amount of symlinks we have to manually maintain
is tedious and error prone. Any ideas on improving thing?

Signed-off-by: Sebastian Wagner <sewagner@redhat.com>
2021-09-03 11:38:04 +02:00
Kefu Chai
ffbc3164d4 cmake: add "mypy" back to tox envlist of "qa""
This reverts commit 286e46578d.

since 0017df2006 has been merged, let's
add mypy back.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2021-07-22 10:09:21 +08:00
Kefu Chai
286e46578d cmake: drop "mypy" from tox envlist of "qa"
this change partially reverts 81305b0da9,
otherwise we have following errors:

tasks/vstart_runner.py:691: error: Definition of "_run_python" in base class "LocalCephFSMount" is incompatible with definition in base class "CephFSMount"
tasks/vstart_runner.py:705: error: Definition of "_run_python" in base class "LocalCephFSMount" is incompatible with definition in base class "CephFSMount"

Signed-off-by: Kefu Chai <kchai@redhat.com>
2021-07-21 11:09:20 +08:00
Sebastian Wagner
ddfb5eb838
qa: convert test_import.py to pytest
Signed-off-by: Sebastian Wagner <sewagner@redhat.com>
2021-07-02 10:35:19 +02:00
Sebastian Wagner
81305b0da9
qa: Add mypy to make check
Signed-off-by: Sebastian Wagner <sewagner@redhat.com>
2021-07-02 10:35:18 +02:00
Kefu Chai
7c1544c04c cmake: do not always add py3 to TOX_ENVS
before this change add_tox_test() always add "py3" to testenv, even the
caller specifies TOX_ENVS explicitly.

after this change, py3 is added only if the caller does not specify any
TOX_ENVS.

this change helps with the readability.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-10-14 15:30:37 +08:00
Kefu Chai
c02748c8df qa: drop flake8-py2 test
as we've dropped py2 support, no need to run flake8 with python2
anymore.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-23 23:00:56 +08:00
Kefu Chai
a7beb90eb0 cmake: add TOX_ENVS keyword to test with listed test envs
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-23 23:00:56 +08:00
Kefu Chai
14722092fd cmake: add import-tasks to run-tox-qa test
to ensure that qa suites are python3 compatible

Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-03-27 14:54:37 +08:00
Thomas Bechtold
bdcc94a1d1 qa: Run flake8 on python2 and python3
To be able to catch problems with python2 *and* python3, run flake8
with both versions. From the flake8 homepage:

It is very important to install Flake8 on the correct version of
Python for your needs. If you want Flake8 to properly parse new
language features in Python 3.5 (for example), you need it to be
installed on 3.5 for Flake8 to understand those features. In many
ways, Flake8 is tied to the version of Python on which it runs.

Also fix the problems with python3 on the way.
Note: This requires now the six module for teuthology. But this is
already an install_require in teuthology itself.

Signed-off-by: Thomas Bechtold <tbechtold@suse.com>
2019-12-13 09:24:20 +01:00
Thomas Bechtold
0127cd1e88 qa: Enable flake8 tox and fix failures
There were a couple of problems found by flake8 in the qa/
directory (most of them fixed now). Enabling flake8 during the usual
check runs hopefully avoids adding new issues in the future.

Signed-off-by: Thomas Bechtold <tbechtold@suse.com>
2019-12-12 10:21:01 +01:00