Commit Graph

56 Commits

Author SHA1 Message Date
melakualehegn 9f0aaf7dd4 Add new-note tox environment
Only reno command was possible to add a
release notes. modify tox config to allow
newnote command too.

Change-Id: I12ac14f664f59dbab11ded5f420de4ea290f21f6
2024-02-29 12:31:16 +00:00
Goutham Pacha Ravi 5f3ed9ff2f Fix coverage job from running with tox4
The tox target needs the coverage script to be
allowed as an external script.

Change-Id: Ifbb780326aac6db7a0b80812caec970164460355
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2023-02-16 11:01:36 -08:00
Akihiro Motoki d04fb0b0fa tox: Declare bash as allowlist_externals
tox4 checks allowlist_externals more strictly and
all externals need to be specified explicitly.

skipsdist=True is also droppped. When skipsdist=True is specified,
a target application is not installed into a tox env, but there
seems no reason to do so. In various other OpenStack projects,
a target applicatin needs to be installed into a tox vnev, for
example, in docs and/or linter jobs and it causes failures with tox4.
I believe dropping it would avoid potential future failures.

Change-Id: I56d2a654f2be87e98026dfa237d5c81d5fcefa37
2023-01-05 18:30:14 +09:00
Ghanshyam Mann 68294505b1 Drop lower-constraints.txt and its testing
As discussed in TC PTG[1] and TC resolution[2], we are
dropping the lower-constraints.txt file and its testing.
We will keep lower bounds in the requirements.txt file but
with a note that these are not tested lower bounds and we
try our best to keep them updated.

[1] https://etherpad.opendev.org/p/tc-zed-ptg#L326
[2] https://governance.openstack.org/tc/resolutions/20220414-drop-lower-constraints.html#proposal

Change-Id: I81024f02006206ea1d58e47d81a6f473ef148c32
2022-04-30 20:19:12 -05:00
dengzhaosen 99c0be8e7f Update python testing classifier
Yoga testing runtime[1] has been updated to add py39
testing as voting. Unit tests update are handled by the
job template change in openstack-zuul-job

- https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/820286

this commit updates the classifier in setup.cfg file.

[1] https://governance.openstack.org/tc/reference/runtimes/yoga.html

Change-Id: I9c7aa6b17073677d15c2b0c6e1e59e73b918fc0f
2021-12-24 08:58:13 +08:00
wu.shiming eb52c16c65 Changed minversion in tox to 3.18.0
The patch bumps min version of tox to 3.18.0 in order to
replace tox's whitelist_externals by allowlist_externals option:
https://github.com/tox-dev/tox/blob/master/docs/changelog.rst#v3180-2020-07-23

Change-Id: I686257fe9ffaefde4d2cdca8ff60a83b908f3b6b
2021-07-06 07:56:10 +00:00
Dina Saparbaeva 9a5947b63d tox miniversion update to 3.1.1
In 3.1.1, tox had fixed:

mishandling the basepython directive [1]
ignoring PYTHONDONTWRITEBYTECODE [2]
More details in [3]

[1] tox-dev/tox#477
[2] tox-dev/tox@336f4f6
[3] http://lists.openstack.org/pipermail/openstack-dev/2018-July/thread.html#132075

Change-Id: I2e5387f284a34c9fc3839503534c21374b11fc0c
2021-02-13 07:51:06 +00:00
Zuul ff2fd88b18 Merge "Updates testenv to py38 and removes RIZON_INTEGRATION_TESTS_CONFIG_FILE" 2021-02-12 22:22:01 +00:00
Dina Saparbaeva b09dc41a0b Updates testenv to py38 and removes RIZON_INTEGRATION_TESTS_CONFIG_FILE
Updates testenv to py38, as I think most developers
have python 3.8 installed on their environment.
And RIZON_INTEGRATION_TESTS_CONFIG_FILE variable is
also removed. According to codesearch it is not used
anywhere.

Change-Id: Id04ee718e9b1026f00c6d5db9d4db3914e23ba5f
2021-02-11 16:55:55 +00:00
Dina Saparbaeva 8f1be60b0a Use TOX_CONSTRAINTS_FILE
Replace deprecated UPPER_CONSTRAINTS_VARIABLE.
Link:  https://zuul-ci.org/docs/zuul-jobs/python-roles.html#rolevar-tox.tox_constraints_file

Change-Id: I0b90a284c35511eb508241bc10c774f3e9be8222
2021-02-11 22:00:03 +06:00
maaoyu fb5c45dfad Remove install unnecessary packages
The docs requirements migrated to doc/requirements.txt
we need not install things from requirements.txt.

Change-Id: I1b2e7e8a6955a3da01e91a29bcbfce69464fbc7b
2020-09-23 13:52:50 +08:00
Akihiro Motoki bbfc3f0a4f tox: specify ignore_basepython_conflict
We specify "basepython = python3" in [testenv] in tox.ini.
Without ignore_basepython_conflict = true, an interpreter named 'python3'
is looked for even for tox envs like py36, py37, py38.
As a result, for example, py38 job will be run against python 3.6
on ubuntu-bionic where python3 is an alias for python3.6.
This issue can be addressed by "ignore_basepython_conflict = true".

Change-Id: If8c90c66adbd6ff34ad6aedd373455a34ec73930
2020-09-04 09:37:14 +09:00
Andreas Jaeger 62031d8a7c Switch to newer openstackdocstheme and reno versions
Switch to openstackdocstheme 2.2.1 and reno 3.1.0 versions. Using
these versions will allow especially:
* Linking from HTML to PDF document
* Allow parallel building of documents
* Fix some rendering problems

Update Sphinx version as well.

Set openstackdocs_pdf_link to link to PDF file. Note that
the link to the published document only works on docs.openstack.org
where the PDF file is placed in the top-level html directory. The
site-preview places the PDF in a pdf directory.

Disable openstackdocs_auto_name to use 'project' variable as name.

Change pygments_style to 'native' since old theme version always used
'native' and the theme now respects the setting and using 'sphinx' can
lead to some strange rendering.

Remove docs requirements from lower-constraints, they are not needed
during install or test but only for docs building.

openstackdocstheme renames some variables, so follow the renames
before the next release removes them. A couple of variables are also
not needed anymore, remove them.

See also
http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014971.html

Change-Id: Ic888f31814431683d8cd71e1ab25c0dc63bcc8ef
2020-05-21 14:01:02 +02:00
Goutham Pacha Ravi d064975150 Drop install_command usage in tox
Use the default value provided by tox:

https://tox.readthedocs.io/en/latest/config.html#conf-install_command

See discussion on the openstack-discuss ML [1]
for the complete context.

Adjust the python-keystoneclient library requirement
to the minimum required by horizon.

[1] http://lists.openstack.org/pipermail/openstack-discuss/2020-April/014237.html

Change-Id: I6344f44fb955d631a4f0a13fa53ecc19826c7ea6
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
2020-04-22 19:31:23 -07:00
Andreas Jaeger 4d19dcd9ea Cleanup py27 support
This repo is now testing only with Python 3, so let's make
a few cleanups:
- Remove python 2.7 stanza from setup.py
- Add requires on python >= 3.6 to setup.cfg so that pypi and pip
  know about the requirement
- Remove obsolete sections from setup.cfg
- Update classifiers
- Update requirements, no need for python_version anymore
- Switch to using sphinx-build
- Use newer openstackdocstheme and Sphinx versions
- Cleanup */source/conf.py to remove now obsolete content.
- Remove Babel from requirements, it's not needed for running.
- Update lower-constraints for osprofiler as required by
  other dependencies.

Change-Id: I84ec7cae5b051bb9c69969d8ccaa28b053914840
2020-04-17 22:28:25 +02:00
Andreas Jaeger ca070fe479 Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Fix problems found.

Remove hacking and friends from lower-constraints, they are not
installed in a running system.

Change-Id: Ia62b221aa0807300eaee7b075607ac6b56256b76
2020-04-01 13:37:50 +02:00
manchandavishal dcf276d829 Drop Django 1.11 support
Django 1.11 ends its extended support in April 2020 (which is before
Ussuri release), so horizon drops Django 1.11 support in Ussuri.

tox envs for non-primary Django versions are no longer needed in tox.ini
as testing environments for non-primary Django versions are setup in
the zuul jobs now.

horizon>=17.1.0 is required to use Django 2.2. requirements.txt and
lower-constraints.txt are updated accordingly. for more info. please
refer [1].
Depends-On: https://review.opendev.org/#/c/700733/
[1] https://etherpad.openstack.org/p/Enable_Django22_support_in_Horizon_Plugin

Change-Id: Ide8df87a29eb94eb17ea9d132a1162f2915948ee
2020-01-01 20:48:13 +00:00
Goutham Pacha Ravi 3cd2fec230 Drop python2.7 support
As per the official python support timeline
set forth by the OpenStack TC [1], OpenStack
Train (in our case, manila-ui 2.19.x
series) is the last release that will support
python2.7.

Depends-On: https://review.opendev.org/#/c/688997/
[1] https://governance.openstack.org/tc/resolutions/20180529-python2-deprecation-timeline.html

Change-Id: I5b4dc1853d7e4f8f736dd2a22eb08bcfdeac3411
2019-11-07 18:15:32 +00:00
manchandavishal 73b7b9cd07 Use Horizon project template for django jobs
Horizon defined a project template 'horizon-non-primary-django-jobs'
for django jobs. This patch use that template to run django jobs
here. For information please refer [1]

[1] https://review.opendev.org/#/c/681969/

Change-Id: I8df240f0f297c0387bef304e285ce8dd9f34c85d
2019-10-14 15:29:22 +00:00
manchandavishal 7c0ca11d7f Update the constraints url
For more detail, see http://lists.openstack.org/pipermail/openstack-discuss/2019-May/006478.html

Change-Id: I8903812d4dbf31ab9d1fcd22721862df8e215593
2019-09-19 15:24:10 +00:00
Zuul 78815b46ab Merge "Add PDF documentation build" 2019-09-14 01:48:20 +00:00
Tom Barron d9a01c0dd7 Add PDF documentation build
Add a new tox target to build PDF documentation in accord
with the community goal [0] to have PDF docs available.

Also, only show genindex and search for HTML.  These elements
do not make sense within PDF documents.

[0] https://governance.openstack.org/tc/goals/selected/train/pdf-doc-generation.html

Change-Id: Ia75423d1efbec65730130eedf169c458b92b0c9f
2019-09-13 23:38:24 +00:00
Zuul 3f4d771bdc Merge "Modify the url of upper_constraints_file" 2019-07-18 13:46:34 +00:00
Corey Bryant 044695fcfc Limit envlist to py37 for Python 3 Train goal
This is a mechanically generated patch to ensure unit testing is in place
for all of the Tested Runtimes for Train. The correct zuul jobs are
already in place so this change just limits default 'tox' calls to py37
to save developers time.

See the Train python3-updates goal document for details:
https://governance.openstack.org/tc/goals/train/python3-updates.html

Change-Id: I12f0713448677e5bedcbcbef36b73ee21f085331
Story: #2005924
Task: #34220
2019-07-11 12:32:00 -04:00
pengyuesheng 55e42a390e Modify the url of upper_constraints_file
For more detail, see http://lists.openstack.org/pipermail/openstack-discuss/2019-May/006478.html

Change-Id: I3811ffd422107dcf05f79fce01482e432aed0b5c
2019-07-02 11:09:32 +08:00
gujin e1c48ee266 Replace git.openstack.org URLs with opendev.org URLs
1. Replace git.openstack.org URLs with opendev.org URLs
2. Remove unncessary "=="

Change-Id: If78b4eefb9bb144f65d7be2f6c898a74f5dc150e
2019-05-27 13:41:50 +08:00
Ivan Kolodyazhny b6924ccf4a Add Python 3.6 and Python 3.7 jobs
According to 'Tested Runtimes for Train' [1] we need to support
Python 2.7, Python 3.7 and Python 3.6 runtimes.

[1] https://governance.openstack.org/tc/reference/runtimes/train.html

Change-Id: I75f56a0fe753bcc1250c4aaf8f191f4bad7d0028
2019-04-15 20:17:12 +03:00
Ghanshyam Mann 628cb22b09 Dropping the py35 testing
All the integration testing has been moved to
Bionic now[1] and py3.5 is not tested runtime for
Train or stable/stein[2].

As per below ML thread, we are good to drop the py35
testing now:
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/005097.html

[1] http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004647.html
[2]
https://governance.openstack.org/tc/reference/runtimes/stein.html
https://governance.openstack.org/tc/reference/runtimes/train.html

Change-Id: I449af10676f087ec75d2ca014045e33dc2a0fa4b
2019-04-14 23:11:09 +00:00
Ian Wienand ca9cb26eee Replace openstack.org git:// URLs with https://
This is a mechanically generated change to replace openstack.org
git:// URLs with https:// equivalents.

This is in aid of a planned future move of the git hosting
infrastructure to a self-hosted instance of gitea (https://gitea.io),
which does not support the git wire protocol at this stage.

This update should result in no functional change.

For more information see the thread at

 http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003825.html

Change-Id: Ieffad700c68c51c084c44af2eda497233f29ceff
2019-03-24 20:34:10 +00:00
Ivan Kolodyazhny 019526b5f8 Add manila-ui integration tests
This patch adds basic tests to verify that manila-ui is
installed and could be opened.

manila-ui-integration-tests job is added in a
non-voting mode.

Depends-On: https://review.openstack.org/634712
Change-Id: I67e876a5cb26637b62225fc854a906dc1a714e76
2019-02-07 10:07:26 +00:00
jacky06 c4df2c9c5b Update hacking version
Use latest release 1.1.0 and compatible changes w.r.t pep8

Change-Id: Idf29433557f48425ba08565cdccbaf06b1acb785
2019-01-10 02:51:53 +00:00
Doug Hellmann 757b6b4fc3 fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: I99ebe4dc0f09994b5a85e0258ad70de4cb76bc32
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-09-26 18:55:57 -04:00
Ivan Kolodyazhny c5ef09e882 Add ability to test Manila UI with Horizon master branch
For the developers needs it's useful to be able run tests with the
latest Horizon version from the master branch.

This patch introduces new tox environment py3-dev to run tests with the
Horizon master branch.

By default, Horizon will be installed from the master branch of it's git
repository. You can override this behaviour by setting HORIZON_REPO
environment variable to test the plugin with your local copy.

Change-Id: Iea6e53eb38ac82817ad893770316db49c141644a
2018-09-12 11:37:54 -06:00
Vu Cong Tuan ad07bfb632 Add py36 testenv
Python 3.6 is installed by default in Ubuntu 18.04 LTS.
Therefore, according to Transition Plan [1],
it'll be handy to have py36 testenv.

For more details, please check Python2 Deprecation Timeline [2]
and Python3-first Goal - Completion Criteria [3].

[1] https://wiki.ubuntu.com/Python/Python36Transition
[2] https://governance.openstack.org/tc/resolutions/20180529-python2-deprecation-timeline.html
[3] https://review.openstack.org/#/c/575933/8/goals/stein/python3-first.rst@42

Change-Id: Ia2fbe35e1724a94ca6162604063a1c787acda596
2018-06-27 10:59:53 +07:00
huang.zhiping bcca46369e fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: Idac327ef35d8317c6e9ae838f2d88c4b5b926606
2018-06-22 00:13:34 -07:00
Akihiro Motoki e3e9135fba Add python3 django 1.11 job instead of django 2.0 job
Django 2.0 is now used in tox py35 job, so there is no need for
py35dj20 job. Instead, Django 1.11 with python3 is not covered.

- py35dj20 job is dropped from tox.ini.
- python3-django111 is added to tox.ini.
  python3 is specified to basepython to avoid a specific python version.
- .zuul.yaml is updated to consume horizon-openstack-tox-python3-django111
  and drop horizon-openstack-tox-py35dj20.

Change-Id: I50713dab7f944cbb9cbead3f00c95be7bb9c623e
2018-06-13 19:28:02 +09:00
Victoria Martinez de la Cruz 39d9896c47 Make manila-ui python3 compatible
In order to make manila-ui python3 compatible,
this patch set:
- replace dict.iteritems() with six.iteritems(dict)
- replace print msg with print(msg)
- replace dict.viewkeys() with error.keys()
- python 3 getting the keys() of a dict returns
  a dict_keys object instead of a list and hence
  sort() fails
- in python 2.x calling keys makes a copy of the key
  that you can iterate over while modifying the dict.
  This doesn't work in python 3.x because keys
  returns an iterator instead of a list.
  Another way is to use list to force a copy of the keys
  to be made.
- use getattr instead of relying on overriden __getattr__
  in the client to get params that not neccesarily need to
  be available (share_group_id and supports_share_migration)
- refactor ShareGroupTypeTests

Plus, enable py35 and py35dj20 jobs in tox and drop
old oslo-incubator files (install_venv.py)

Also add openstack-tox-py35 job to check python3 env.
openstack-tox-py35 should be defined in project-config later
but it is added to check python3 UT status.

Change-Id: I30582184904dc19e9cb4ca171b1fd2d161e09c48
2018-05-07 02:03:21 +09:00
Doug Hellmann cdf90f2f34 add lower-constraints job
Create a tox environment for running the unit tests against the lower
bounds of the dependencies.

Create a lower-constraints.txt to be used to enforce the lower bounds
in those tests.

Add openstack-tox-lower-constraints job to the zuul configuration.

Note that manila-ui does not support python3 yet so lower-constraints
env uses python2 unlike other projects.

See http://lists.openstack.org/pipermail/openstack-dev/2018-March/128352.html
for more details.

Co-Authored-By: Akihiro Motoki <amotoki@gmail.com>
Change-Id: Ia808cae058ab5d7bd5435ad57543eb8b9bcc96db
Depends-On: https://review.openstack.org/555034
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Signed-off-by: Akihiro Motoki <amotoki@gmail.com>
2018-04-22 09:46:45 +09:00
blue55 da983564ea Enable some off-by-default checks
Some of the available checks are disabled by default, like:
[H106] Don’t put vim configuration in source files
[H203] Use assertIs(Not)None to check for None

Change-Id: I884837a9fee9572dda2240efdf27d6f4c607f139
2017-06-21 15:57:10 +08:00
Tatiana Ovchinnikova eeb254081c Update tox envlist
Django 1.7 is not supported for a few releases and
can be easily removed from test env. Also, Django 1.10
unit tests are included to envlist to help make them
voting tests.

Change-Id: I6407180888fabd223e0393ef9e24de5a3558c25b
2017-04-19 12:55:25 +04:00
Tom Barron 1a20fe71fb Clean docs/build before building docs
Change-Id: I73ad7290f9bd25385bef3ccbf990608904ee1e08
2017-03-03 14:03:55 -05:00
Jeremy Liu cca54ba3e2 Correct the actual path for setting DJANGO_SETTINGS_MODULE
The true path should be "manila_ui.tests.settings" while
"manila_ui.test.settings" is given.

Change-Id: I2510174b6790aa6defaed5b8bf804875eb888ebc
Closes-Bug: #1668990
2017-03-01 22:00:31 +08:00
Tatiana Ovchinnikova 41dc9b7df5 Use upper constraints in tox installs
Openstack infra now supports upper constraints for all jobs.
This patch adds upper constaints for test environment setup.

Change-Id: I86312653e2b044e7180a9201addd48b29aa61bba
Closes-Bug: #1596246
2016-08-25 13:10:02 +03:00
Jenkins 56c9538b9d Merge "Update Django 1.10 tox env" 2016-08-10 15:03:55 +00:00
Tatiana Ovchinnikova 6014aebed3 Update Django 1.10 tox env
Django 1.10 is released and the corresponding tox env can be
updated to strictly look for the version.

Change-Id: I642c16a35eb8cc470c9374e987368c461280dcde
2016-08-05 10:14:59 +03:00
liyifeng 2da584cf59 Delete openstack/common from the exclude list of flake8 in tox
The directory openstack/common was used to keep codes
from oslo-incubator, we have retired oslo-incubator,
so don't use this directory any more.

Change-Id: I177e0cd7e446c7bd1cd5a60d7f4a07cedd9a1072
2016-08-04 17:12:16 +08:00
Tatiana Ovchinnikova 62f2f5a776 Fix unit tests for Django 1.9
This patch set makes manila-ui code work with Django 1.9:

- replaces deprecated django.utils.unittest with unittest
- removes {% load url from future %} lines
- replaces old-style urlpatterns with new ones

Also, since Django < 1.7 is not supported any more by upstream,
this patch removes Django 1.4 from tests and replaces it with
Django 1.9 (while it's not in upstream yet) and Django 1.10.

Change-Id: I28f72ba799aeb2f583db00515dceef41c68170af
Closes-Bug: #1598169
2016-07-21 19:18:14 +03:00
Goutham Pacha Ravi 31bd6e3366 Add support for releasenotes
Create the releasenotes directory and add the requisite
conf.py file to generate manila-ui's release notes.

project-config change: Ibb5e84e621ee0dadd8f6748252536a6447202611

Change-Id: I7a129c47bc3eba904754f4ec8e8140d42b29a0d1
2016-05-25 17:19:09 +00:00
vponomaryov 72f6c06a11 Upgrade coverage tox job
Add ported from Manila project 'cover.sh' script that
allows to calculate coverage diff between last and previous commits.

Usage of new approach (with diff):

$ tox -e cover

To run old coverage approach use following:

./run_tests.sh --coverage --no-pep8

Change-Id: I8f6de6ba5cba2050771c4bead31baaf975e097b9
2016-04-20 14:37:33 +03:00
Zhenguo Niu 7ca7311979 Remove "builtins = _" from tox.ini
"_" (ugettext_lazy) is defined by usual imports,
so "builtins = _" in tox.ini is unnecessary.

Change-Id: I4616811b58a17e84c9c4ba32f01004af3aee8feb
2015-12-24 11:01:38 +08:00