Browse Source

Switch to stestr

According to Openstack summit session [1],
stestr is maintained project to which all Openstack projects should migrate.
Let's switch to stestr as other projects have already moved to it.

[1] https://etherpad.openstack.org/p/YVR-python-pti

Change-Id: I753f32ecf3275cf49d8c93bf648a6a26bc6da8e7
tags/3.28.0
Vu Cong Tuan 11 months ago
parent
commit
a9d728b71e
7 changed files with 9 additions and 13 deletions
  1. 1
    2
      .gitignore
  2. 3
    0
      .stestr.conf
  3. 0
    7
      .testr.conf
  4. 1
    1
      lower-constraints.txt
  5. 1
    1
      oslo_concurrency/lockutils.py
  6. 1
    0
      test-requirements.txt
  7. 2
    2
      tox.ini

+ 1
- 2
.gitignore View File

@@ -25,8 +25,7 @@ pip-log.txt
25 25
 .coverage
26 26
 cover
27 27
 .tox
28
-nosetests.xml
29
-.testrepository
28
+.stestr
30 29
 
31 30
 # Translations
32 31
 *.mo

+ 3
- 0
.stestr.conf View File

@@ -0,0 +1,3 @@
1
+[DEFAULT]
2
+test_path=./oslo_concurrency/tests/unit
3
+top_path=./

+ 0
- 7
.testr.conf View File

@@ -1,7 +0,0 @@
1
-[DEFAULT]
2
-test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
3
-             OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \
4
-             OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-60} \
5
-             ${PYTHON:-python} -m subunit.run discover -t ./ . $LISTOPT $IDOPTION
6
-test_id_option=--load-list $IDFILE
7
-test_list_option=--list

+ 1
- 1
lower-constraints.txt View File

@@ -54,7 +54,7 @@ snowballstemmer==1.2.1
54 54
 Sphinx==1.6.2
55 55
 sphinxcontrib-websupport==1.0.1
56 56
 stevedore==1.20.0
57
-testrepository==0.0.18
57
+stestr==2.0.0
58 58
 testtools==2.2.0
59 59
 traceback2==1.4.0
60 60
 unittest2==1.1.0

+ 1
- 1
oslo_concurrency/lockutils.py View File

@@ -348,7 +348,7 @@ def _lock_wrapper(argv):
348 348
     lockutils-wrapper
349 349
 
350 350
     If you run this:
351
-        lockutils-wrapper python setup.py testr <etc>
351
+        lockutils-wrapper stestr run <etc>
352 352
 
353 353
     a temporary directory will be created for all your locks and passed to all
354 354
     your tests in an environment variable. The temporary dir will be deleted

+ 1
- 0
test-requirements.txt View File

@@ -7,6 +7,7 @@ oslotest>=3.2.0 # Apache-2.0
7 7
 coverage!=4.4,>=4.0 # Apache-2.0
8 8
 futures>=3.0.0;python_version=='2.7' or python_version=='2.6' # BSD
9 9
 fixtures>=3.0.0 # Apache-2.0/BSD
10
+stestr>=2.0.0 # Apache-2.0
10 11
 
11 12
 # These are needed for docs generation
12 13
 openstackdocstheme>=1.18.1 # Apache-2.0

+ 2
- 2
tox.ini View File

@@ -10,8 +10,8 @@ deps =
10 10
  -r{toxinidir}/requirements.txt
11 11
 # We want to support both vanilla stdlib and eventlet monkey patched
12 12
 commands =
13
-    lockutils-wrapper python setup.py testr --slowest --testr-args='{posargs}'
14
-    env TEST_EVENTLET=1 lockutils-wrapper python setup.py testr --slowest --testr-args='{posargs}'
13
+    lockutils-wrapper stestr run --slowest {posargs}
14
+    env TEST_EVENTLET=1 lockutils-wrapper stestr run --slowest {posargs}
15 15
 
16 16
 [testenv:py27]
17 17
 basepython = python2.7

Loading…
Cancel
Save