diff --git a/doc/requirements.txt b/doc/requirements.txt new file mode 100644 index 0000000..6534098 --- /dev/null +++ b/doc/requirements.txt @@ -0,0 +1,4 @@ +openstackdocstheme>=1.11.0 # Apache-2.0 +reno>=0.1.1 # Apache2 +sphinx!=1.6.6,!=1.6.7,<2.0.0;python_version=='2.7' # BSD +sphinx!=1.6.6,!=1.6.7,!=2.1.0;python_version>='3.4' # BSD diff --git a/subunit2sql/shell.py b/subunit2sql/shell.py index 9e53ac4..00f2b74 100644 --- a/subunit2sql/shell.py +++ b/subunit2sql/shell.py @@ -31,7 +31,8 @@ CONF = cfg.CONF CONF.import_opt('verbose', 'subunit2sql.db.api') SHELL_OPTS = [ - cfg.MultiStrOpt('subunit_files', positional=True, + cfg.MultiStrOpt('subunit_files', positional=True, required=False, + default=None, help='list of subunit files to put into the database'), cfg.DictOpt('run_meta', short='r', default=None, help='Dict of metadata about the run(s)'), diff --git a/test-requirements.txt b/test-requirements.txt index fcf5c13..d54a05f 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -1,18 +1,14 @@ -hacking>=0.12.0,!=0.13.0,<0.14 +hacking>=2.0.0,<2.1.0 coverage>=3.6 fixtures>=0.3.14 mock>=1.0 -sphinx!=1.6.6,!=1.6.7,<2.0.0;python_version=='2.7' # BSD -sphinx!=1.6.6,!=1.6.7,!=2.1.0;python_version>='3.4' # BSD testscenarios>=0.4 -stestr>=1.0.0 +stestr<3.0.0;python_version=='2.7' # BSD +stestr>=1.0.0;python_version>='3.4' # BSD testtools>=0.9.34 PyMySql psycopg2 oslo.concurrency>=3.5.0 -# releasenotes -reno>=0.1.1 # Apache2 -openstackdocstheme>=1.11.0 # Apache-2.0 # This is needed for oslo.db test code to be imported, it's not # directly installed by oslo.db testresources>=0.2.4 # Apache-2.0/BSD diff --git a/tools/test-setup.sh b/tools/test-setup.sh index 07a0785..505a58c 100755 --- a/tools/test-setup.sh +++ b/tools/test-setup.sh @@ -23,8 +23,8 @@ sudo -H mysqladmin -u root password $DB_ROOT_PW sudo -H mysql -u root -p$DB_ROOT_PW -h localhost -e " DELETE FROM mysql.user WHERE User=''; FLUSH PRIVILEGES; - GRANT ALL PRIVILEGES ON *.* - TO '$DB_USER'@'%' identified by '$DB_PW' WITH GRANT OPTION;" + CREATE USER '$DB_USER'@'%' IDENTIFIED BY '$DB_PW'; + GRANT ALL PRIVILEGES ON *.* TO '$DB_USER'@'%' WITH GRANT OPTION;" # Now create our database. mysql -u $DB_USER -p$DB_PW -h 127.0.0.1 -e " diff --git a/tox.ini b/tox.ini index 8befe6f..7dccbdb 100644 --- a/tox.ini +++ b/tox.ini @@ -41,6 +41,8 @@ commands = {posargs} [testenv:docs] basepython = python3 +deps = + -r{toxinidir}/doc/requirements.txt commands = python setup.py build_sphinx @@ -50,7 +52,10 @@ commands = python setup.py build_sphinx # E129 skipped because it is too limiting when combined with other rules # H305 skipped because it is inconsistent between python versions # E711 skipped because sqlalchemy filter() requires using == instead of is -ignore = E125,E123,E129,H305,E711 +# TODO (gmann): we have to bump the hacking version to 2.0.0 to fix the gate which is +# failing for new pip resolver. That is why F601,E402,W605,W504,E305,E117 are +# skipped temporary. +ignore = E125,E123,E129,H305,E711,F601,E402,W605,W504,E305,E117 exclude = .venv,.git,.tox,dist,doc,*egg,build,releasenotes [testenv:generate_samples] @@ -62,6 +67,8 @@ commands = [testenv:releasenotes] basepython = python3 +deps = + -r{toxinidir}/doc/requirements.txt commands = sphinx-build -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html [testenv:bindep]