diff options
author | Vu Cong Tuan <tuanvc@vn.fujitsu.com> | 2018-07-11 13:41:06 +0700 |
---|---|---|
committer | Vu Cong Tuan <tuanvc@vn.fujitsu.com> | 2018-07-11 14:51:22 +0700 |
commit | 9f70179a3dfac5f7c1be5062e8552cdad544ea2d (patch) | |
tree | 6e05005d9feda334ec658232707cbab52c53b964 | |
parent | 9d34339c063617e0f8d55013c4e27da4067beb0e (diff) | |
download | python-designateclient-9f70179a3dfac5f7c1be5062e8552cdad544ea2d.tar.gz |
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: I96c7c264dab04a7f52e2c77a1165ed51137bfae0
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | .stestr.conf | 4 | ||||
-rw-r--r-- | .testr.conf | 10 | ||||
-rw-r--r-- | lower-constraints.txt | 3 | ||||
-rw-r--r-- | test-requirements.txt | 2 | ||||
-rwxr-xr-x | tools/pretty_tox.sh | 6 | ||||
-rw-r--r-- | tox.ini | 10 |
7 files changed, 16 insertions, 23 deletions
@@ -21,6 +21,6 @@ doc/source/reference/api/* doc/build/* dist designateclient/versioninfo -.testrepository +.stestr/ *.log -.idea/
\ No newline at end of file +.idea/ diff --git a/.stestr.conf b/.stestr.conf new file mode 100644 index 0000000..86a8dc7 --- /dev/null +++ b/.stestr.conf @@ -0,0 +1,4 @@ +[DEFAULT] +test_path=${OS_TEST_PATH:-./designateclient/tests} +top_dir=./ + diff --git a/.testr.conf b/.testr.conf deleted file mode 100644 index 5325b9e..0000000 --- a/.testr.conf +++ /dev/null @@ -1,10 +0,0 @@ -[DEFAULT] -test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \ - OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \ - OS_LOG_CAPTURE=${OS_LOG_CAPTURE:-1} \ - OS_DEBUG=${OS_DEBUG:-1} \ - OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-160} \ - ${PYTHON:-python} -m subunit.run discover -t ./ ${OS_TEST_PATH:-./designateclient/tests} $LISTOPT $IDOPTION - -test_id_option=--load-list $IDFILE -test_list_option=--list diff --git a/lower-constraints.txt b/lower-constraints.txt index 14ba902..a380f86 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -68,10 +68,9 @@ requestsexceptions==1.2.0 rfc3986==0.3.1 simplejson==3.5.1 six==1.10.0 -stestr==1.0.0 stevedore==1.20.0 tempest==17.1.0 -testrepository==0.0.18 +stestr==2.0.0 testtools==2.2.0 traceback2==1.4.0 unittest2==1.1.0 diff --git a/test-requirements.txt b/test-requirements.txt index fb347d0..c619d21 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -10,6 +10,6 @@ oslotest>=3.2.0 # Apache-2.0 os-testr>=1.0.0 # Apache-2.0 python-subunit>=1.0.0 # Apache-2.0/BSD requests-mock>=1.2.0 # Apache-2.0 -testrepository>=0.0.18 # Apache-2.0/BSD +stestr>=2.0.0 # Apache-2.0 reno>=2.5.0 # Apache-2.0 tempest>=17.1.0 # Apache-2.0 diff --git a/tools/pretty_tox.sh b/tools/pretty_tox.sh deleted file mode 100755 index 0fc3605..0000000 --- a/tools/pretty_tox.sh +++ /dev/null @@ -1,6 +0,0 @@ -#! /bin/sh - -TESTRARGS=$1 - -exec 3>&1 -status=$(exec 4>&1 >&3; ( python setup.py testr --slowest --testr-args="--subunit $TESTRARGS"; echo $? >&4 ) | subunit-trace -f) && exit $status @@ -21,7 +21,7 @@ whitelist_externals = find commands = find . -type f -name "*.pyc" -delete - sh tools/pretty_tox.sh '{posargs}' + stestr run --slowest {posargs} passenv = http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY [testenv:docs] @@ -46,7 +46,13 @@ commands = flake8 [testenv:cover] basepython = python3 -commands = python setup.py testr --coverage --testr-args='{posargs}' +setenv = + PYTHON=coverage run --source designateclient --parallel-mode +commands = + stestr run '{posargs}' + coverage combine + coverage html -d cover + coverage xml -o cover/coverage.xml [testenv:venv] basepython = python3 |