to python2.7 so that running locally will succeed
and the results will match those for the gate
pylint job.
Partial-Bug: #1673824
Change-Id: I6c45a32ba8e77c35403357b0100379bb536a36b3
Our form of todo extension does not work with sphinx 1.5.2.
Remove it to unblock gate: we can add todos back in later with
more current methods. Also clean up some dangling cross-references
in the doc.
Co-Authored-By: Valeriy Ponomaryov <vponomaryov@mirantis.com>
Change-Id: If74b9e32ad2b5d8d70da60895d85588ff993797e
Make use of doc8 to verify all rst files which are not
autogenerated for errors and fail if there are any issues
found. The doc8 checks are now part of the tox 'docs'
environment and ran automatically. Checks can also be called
direcly via 'tox -e docs'.
Fix all issues found by doc8.
Closes-Bug: #1664841
Change-Id: I9215524d35646de7485504e4c5ff86fd91a1d09f
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
The gating on python 3.4 is restricted to <= Mitaka. This is due to
the change from Ubuntu Trusty to Xenial, where only python3.5 is
available. There is no need to continue to keep these settings.
Change-Id: Id8a9dda9ea25b47afc35e0605f4df2f3f22c5f38
Our current tox configuration provides no support for python 3.5
even though it is the version that ships with current ubuntu
(xenial) and Fedora (25) systems, and even though in gate the
python3 jobs run on xenial with python 3.5.
Add py35 env to tox.ini alongside py34, py27, and pep8.
TrivialFix
Change-Id: Ib32069f9185c5233c8f96164781ec66c56db33bd
Drop the undesired executable bit for the following files:
1. manila_tempest_tests/services/share/v2/json/shares_client.py
2. manila_tempest_tests/tests/api/test_share_networks.py
Also add pep8 check for new executable files under manila_tempest_tests.
Change-Id: Iaa509fdf4e0ebeb60d71b053f62459992c938468
releasenotes and venv tox jobs had redefined the install_command
to reinstall any packages from requirements/test-requirements files.
Since Infra started supporting constrained requirements for these
jobs as well, we can drop the reinstall command.
Ref:
http://lists.openstack.org/pipermail/openstack-dev/2016-August/101474.html
Change-Id: Ib4b8c6cef22a9911030c2e3e3f5281e7e22575fc
The API Documentation team has requires [1] that
projects maintain their api-reference in-tree and
build it to the developer.openstack.org website.
This version of the API reference uses os-api-ref
and compiles API documentation close to that of
the OpenStack compute service (nova).
Co-Authored-By: Goutham Pacha Ravi <gouthamr@netapp.com>
[0] http://lists.openstack.org/pipermail/openstack-dev/2016-May/093765.html
Implements: bp move-manila-api-reference-in-tree
Change-Id: I67bb3354162d6e0e00fa2788edde864cc14920ee
OpenStack CI supports now constraints in the coverage job - as a first
job to check that the recent changes for zuul-cloner work correctly.
Use constraints for cover environment.
Change-Id: I81a985a2049221a8a7ac1f20642137f22847973f
The commands used by constraints need at least tox 2.0. Update to
reflect reality, which should help with local running of constraints
targets.
Change-Id: I27348462a21daab479d76b24b48e3a4e017504cc
The tox targets do not currently use upper constaints, resulting in
stable branch test runs pulling down newer library versions than what
should be supported for those releases.
This adds upper-constaints for test environment setup.
Change-Id: I1ff164242901a891fb45da03b1595b2e9246a765
Closes-bug: #1596246
Manila has more dynamically created dirs than we exclude in
pep8 job. Such as 'build' and 'cover'.
Therefore, exclude them too to speed up passing of pep8 job on dev
machine where lots of dynamically created things exist.
TrivialFix
Change-Id: I256720846acdd584cadaf59e9dedaad0ff741ae3
The bashate tool has been upgraded and now issues new warnings.
Squash these E042 and E043 warnings since our shell scripts
are doing the right thing currently and changing them to avoid
the warnings makes them less readable and more fragile.
Change-Id: I25ff337160ab176bb150a6186f6c3198cc068732
Grenade is an OpenStack test harness to exercise the upgrade
process between releases. It uses DevStack to perform an initial
OpenStack install and as a reference for the final configuration.
Add support of it to Manila project, doing following changes:
- Add all required scripts for 'grenade' job, such as following:
-- settings
-- shutdown.sh
-- upgrade.sh
- Add optional 'resources.sh' script that performs functional
tests using bash and manilaclient. List of scenarios:
-- 1. create and delete share setting metadata and access rule
-- 2. attach security service to share network
-- 3. update quotas
-- 4. create private share type and add access for project
Note following:
- Tempest is not used by design.
- Manilaclient is used of stable version - version of 'base' devstack,
which is 'stable/mitaka'. It also means that used API microversion
is latest for that branch.
Change-Id: I7d7e0c50933776ca1a710bcf069abb0282b821ac
Depends-On: I4232382d3c944666bbf0916a3f285b84f6ff9d64
Implements blueprint grenade
When running pep8 checks, fail if executable
files have accidentally been added.
Co-Authored-By: Eric Harney <eharney@redhat.com>
Closes-Bug: 1566328
Change-Id: I7280c0403cd473cd4b88cfc021d4f605a7bb35f2
This patch removes unused global LOG variable
and logging imports from various manila modules,
and adds a script to be run as part of pep8 that
will ensure that these do not creep back into
the codebase.
Change-Id: I162c4b2478df45aaf6ea8009b102d6de1a4e309e
bashate, which is invoked when running 'tox -epep8', currently
emits many 'E006: Line too long' warnings. We apparently don't
really care about line length in shell scripts and ignore these
warnings.
This commit instructs bashate to suppress these warnings so that
we can see any warnings that we really care about.
Change-Id: I565aeaef1f0590e5a6ee6a866974765c748f2965
This commit ports over the fast8 option from cinder, which enables
one to run pep8 only on one's changeset rather than against the
whole body of code via:
tox -efast8
Change-Id: Icb0286c3c66983f2f106c163cb11c690b2c57849
The ostestr command provides a wrapper around the testr command.
By default it also has output that is much more useful for OpenStack’s
test including lists of all and failed tests and lists of the 10
slowest tests.
ref:
http://docs.openstack.org/developer/os-testr/ostestr.html
Change-Id: If005d1987b2a4e586cf35f0cc1d07739f84235d2
Due to the hacking version update several pep8 checks where ignored
in the flakes8 section of the tox.ini. Removed ignored checks and fixed
appropriate pep8 issues.
The list of fixed issues:
- H105 Don't use author tags
- H238 Old style class declaration, use new style (inherit from `object`)
- H501 Do not use self.__dict__ for string formatting
Closes-Bug: 1530719
Change-Id: I890ba4c54b0da10060767620ff5ff7e480d79a9c
We bump hacking>=0.10.0, and hacking removed some rules, for
the full list of rules please see [1]. So don't need them any more.
Hacking related commits:
Remove H904 in commit b1fe19ebebe47a36b905d709467f5e82521bbd96
Add H105 using author tags
Add H238 hacking no old style class
Add H501 hacking no locals
[1]https://github.com/openstack-dev/hacking/blob/master/setup.cfg#L30
Change-Id: I6a1f3c3ef22be0962ffb81a5da5660837552e5d7
Once we add debug testenv, we can use "tox -e debug -- --debug"
to debug test cases when tox is running.
Change-Id: If12d6c7bd8b1ae04096b526ad37978f60fdb70db
In the tox.ini, [flake8] section, "exclude =
.venv,.tox,dist,doc,openstack,*egg". From this rule, all 'openstack'
directories are excluded. This rule is intended to exclude
manila/openstack/common code check, but this is wrong
because it also exclude checks against manila/api/openstack and
manila/tests/api/openstack. We should fix it
Change-Id: Ie820e3931e83a82c40b0d9b9d943787a5d6ec363
Closes-Bug: #1529092
To solve the problem of "db type could not be determined" on py34 we
have to run first the py34 env to, then, run py27. This patch puts py34
first on the tox.ini list of envs to avoid this problem to happen.
Change-Id: Id54bb80944385579cfa136fce78cb5be55393f81
Closes-Bug: #1489059
Because python creates pyc files during tox runs, certain
changes in the tree, like deletes of files, or switching
branches, can create spurious errors.
Change-Id: I9e3b8c8cb0e6df8f3b67ec9d4fc5bc5d25356d16
Closes-Bug: #1520036
For the moment we can just calculate coverage and generate html with results.
It would be really useful to be able to get 'failure' by this job, when
latest commit introduced reduction of test coverage by any reason - either
addon of new code not covered with unit tests or deletion of existing unit
tests.
It will reduce total required efforts for code reviewers, that are forced now
to perform such check separately and inform about it committer.
Added file 'tools/cover.sh' is taken from OpenStack Rally project as
of state [1], with couple of fixes for satisfying 'bashate'.
Also add configuration file for coverage package.
[1] I7b4defe187c0631928d70bd09d7bcea956f4eed3
Change-Id: Ie0c5721985ae48256d9bb26af5fdb4b05797b359
The desired OS_TEST_DBAPI_ADMIN_CONNECTION string is now reflected
in the oslo.db 1.12.0 release's default behavior, and so does not
need to be set any longer to achieve the same opportunistic backend
discovery for tests.
Change-Id: I9e7239c71371bc872f5ae41e4f0f3c8942f3d9b3
Set the OS_TEST_DBAPI_ADMIN_CONNECTION override variable so that
oslo.db opportunistic detection will know to use PyMySQL until
I12b32dc097a121bd43991bc38dd4d289b65e86c1 makes it the default
behavior.
Change-Id: I1b27cbdc0612ac63501e2f132bab1c065fe9a3ba
Co-Authored-By: Victor Sergeyev <vsergeyev@mirantis.com>
Manila scripts located in bin/* should be covered with unit tests.
In order to add unit tests for bin/* scripts:
- all
- api
- manage
- scheduler
- share
we move them into manila/cmd and use pbr to setup console scripts
which will call the respective main function of each script under manila/cmd.
It will allow us to import from manila.cmd and individually test each 'main' function.
Add unit tests for manila/cmd/* scripts.
Implements bp unit-tests-for-manila-scripts
Change-Id: I9be6b948a6de7ba76405411e98d7531cf225b57e
The program tools/lintstack.py which is executed by
tools/lintstack.sh when Jenkins runs, only tests for differences
in the output of pylint. Right now, there seems to be
17 errors/warnings that are being carried over from fix to fix,
with no difference between fixes, and so no failures in the
pylint Jenkins job.
It is really difficult to tell what the errors are, so this fix
allows developers determine what the errors are by running the
following command:
$ tox -e lint
A sample output of the command is available as an attachment
to the bug.
Change-Id: I88487829576d55d437b934e08571013b7a6e57cf
Signed-off-by: Luis Pabón <lpabon@redhat.com>
Closes-Bug: #1356588
Signed-off-by: Luis Pabón <lpabon@redhat.com>
bashate checks shell script syntax (similar to pep8 for python). Fix
currently available scripts and enable the check for the scripts.
Change-Id: I33dc8c44a58f40e8bca9e29cd717caf46e5cd586
The config module in oslo-incubator has been replaced by oslo.config.
Projects need to switch completely to oslo.config for kilo.
This patch does:
* Register options with oslo.config (new file manila/opts.py)
* Generate the config file using oslo-config-generator
* Remove obsoleted entries for this from openstack-common.conf
* Remove oslo-incubator config files
Change-Id: I30b594423c08782e13a1f615099ae65f997a8551
Closes-Bug: #1382183
tox -e genconfig and tox -e pylint both will generate a warning like:
WARNING:test command found but not installed in testenv
cmd: /bin/bash
env: /home/aj/vcs/OpenStack/openstack/manila/.tox/genconfig
Maybe forgot to specify a dependency?
Whitelist bash to remove the warning.
Change-Id: Ibab38ce2308760c7089d5d3e298bfc642367e7b4