Get WSME tests working again
It had been a long time since WSME had any patches, so the tests had not been run in a while. This corrects errors found while bring the tests back to work. Change-Id: I67efc4151d6eaec673b431904aa7288a7501cb43 Co-Authored-By: 98k <18552437190@163.com>
This commit is contained in:
parent
9d2d21e4c1
commit
3957f12aa2
6
tox.ini
6
tox.ini
@ -1,5 +1,5 @@
|
||||
[tox]
|
||||
envlist = py27,py27-nolxml,pypy,tg11,tg15,cornice,cornice-py3,coverage,py35,py35-nolxml,pecan-dev27,pecan-dev35,pep8
|
||||
envlist = py27,py27-nolxml,pypy,tg11,tg15,cornice,cornice-py3,coverage,py35,py36,py35-nolxml,py36-nolxml,pecan-dev27,pecan-dev35,pecan-dev36,pep8
|
||||
|
||||
[common]
|
||||
testtools =
|
||||
@ -48,7 +48,7 @@ deps =
|
||||
{[common]testtools}
|
||||
transaction
|
||||
suds-jurko
|
||||
https://github.com/stackforge/pecan/zipball/master
|
||||
https://github.com/pecan/pecan/zipball/master
|
||||
|
||||
[testenv:pecan-dev27]
|
||||
basepython = python2.7
|
||||
@ -71,7 +71,6 @@ setenv =
|
||||
commands =
|
||||
{envbindir}/coverage erase
|
||||
{envbindir}/coverage combine
|
||||
{envbindir}/coverage xml wsme/*.py wsme/rest/*.py wsmeext/*.py
|
||||
{envbindir}/coverage report --show-missing wsme/*.py wsme/protocols/*.py wsmeext/*.py
|
||||
|
||||
[testenv:doc]
|
||||
@ -869,7 +868,6 @@ deps =
|
||||
basepython = python3
|
||||
commands =
|
||||
{envbindir}/coverage run {envbindir}/nosetests --nologcapture --with-xunit --xunit-file nosetests-{envname}.xml wsme/tests wsmeext/tests tests/pecantest tests/test_sphinxext.py tests/test_flask.py --verbose {posargs}
|
||||
{envbindir}/coverage xml -o coverage-{envname}.xml wsme/*.py wsme/rest/*.py wsmeext/*.py
|
||||
{envbindir}/coverage report --show-missing wsme/*.py wsme/rest/*.py wsmeext/*.py
|
||||
deps =
|
||||
{[common]testtools}
|
||||
|
@ -102,7 +102,7 @@ def array_from_params(datatype, params, path, hit_paths):
|
||||
|
||||
if iscomplex(datatype.item_type):
|
||||
attributes = set()
|
||||
r = re.compile('^%s\.(?P<attrname>[^\.])' % re.escape(path))
|
||||
r = re.compile(r'^%s\.(?P<attrname>[^\.])' % re.escape(path))
|
||||
for p in params.keys():
|
||||
m = r.match(p)
|
||||
if m:
|
||||
@ -127,7 +127,7 @@ def array_from_params(datatype, params, path, hit_paths):
|
||||
return value
|
||||
|
||||
indexes = set()
|
||||
r = re.compile('^%s\[(?P<index>\d+)\]' % re.escape(path))
|
||||
r = re.compile(r'^%s\[(?P<index>\d+)\]' % re.escape(path))
|
||||
|
||||
for p in params.keys():
|
||||
m = r.match(p)
|
||||
@ -149,7 +149,7 @@ def array_from_params(datatype, params, path, hit_paths):
|
||||
def dict_from_params(datatype, params, path, hit_paths):
|
||||
|
||||
keys = set()
|
||||
r = re.compile('^%s\[(?P<key>[a-zA-Z0-9_\.]+)\]' % re.escape(path))
|
||||
r = re.compile(r'^%s\[(?P<key>[a-zA-Z0-9_\.]+)\]' % re.escape(path))
|
||||
|
||||
for p in params.keys():
|
||||
m = r.match(p)
|
||||
|
Loading…
x
Reference in New Issue
Block a user