Commit Graph

30 Commits

Author SHA1 Message Date
Alex Kavanagh 655f36440f Updates for caracal tox.ini
Update the tox.ini file(s) to use the constraints file from
zaza-openstack-tests.

Change-Id: I5972e75f101fe211e53983ef659346ff2f4780f4
2024-02-24 20:11:33 +00:00
Liam Young f33375073a Fix charm for tox4 compatibility
Related-Bug: 2002788
Change-Id: I210cc3cd05f8f02d170a6b273aefcba51d0740f0
2023-01-17 14:55:34 +00:00
Corey Bryant 57539ec87d Build separately for each supported series and use binary builds
Charms for OpenStack Yoga supports both Ubuntu Focal and Jammy
which means Python 3.8 and Python 3.10.  Managing dependencies
across those two versions is non-trivial and we need to build
the charm on the series the charm is supposed to support.

Switch to using a binary build which allows pip's dependency
resolution to work.

Change-Id: If7ccdcaa900a3276c6e8eb124cdb0f605b20d6c3
2022-09-29 13:04:07 +00:00
Corey Bryant c2c174f539 Add Kinetic and Zed support
* sync charm-helpers to classic charms
* change openstack-origin/source default to zed
* align testing with zed
* add new zed bundles
* add zed bundles to tests.yaml
* add zed tests to osci.yaml and .zuul.yaml
* update build-on and run-on bases
* add bindep.txt for py310
* sync tox.ini and requirements.txt for ruamel
* use charmcraft_channel 2.0/stable
* drop reactive plugin overrides
* move interface/layer env vars to charmcraft.yaml

Change-Id: I2c98ab0f82aa6d6d0a43365cee04d6da34a39ce4
2022-08-31 19:58:26 +01:00
Alex Kavanagh bb172c5c03 Updates to enable jammy and finalise charmcraft builds
- Add 22.04 to charmcraft.yaml
- Update metadata to include jammy
- Remove impish from metadata
- Update osci.yaml to include py3.10 default job
- Modify tox.ini to remove py35,py36,py37 tox target and add py310
  target.
- ensure that the openstack-origin is yoga
- Pin setuptools < 50.0 in src/wheelhouse.txt

Change-Id: I29b80b1e4797eb794c0e2611e732c376d99c270f
2022-04-08 12:30:57 -04:00
Alex Kavanagh e7ada778b9 Update to build using charmcraft
Due to a build problem with the reactive plugin, this change falls back
on overriding the steps and doing a manual build, but it also ensures
the CI system builds the charm using charmcraft.  Changes:

- add a build-requirements.txt
- modify charmcraft.yaml
- modify osci.yaml
    -> indicate build with charmcraft
- modify tox.ini
    -> tox -e build does charmcraft build/rename
    -> tox -e build-reactive does the reactive build
- modify bundles to use the <charm>.charm artifact in tests.
  and fix deprecation warning re: prefix
- tox inception to enable tox -e func-test in the CI

Change-Id: I1e798c9267085d50797b8988f50e99ac9184be33
2022-02-01 19:57:43 +00:00
Corey Bryant 6f312a6c5d Additional test updates
* drop trusty/xenial metadata and function tests
* switch to release-specific zosci functional tests
* switch to yoga zosci unit test job
* add py39

Change-Id: Ie263f9a14edfe9d3ffdaaff996bbe6e34def21c5
2021-11-17 14:46:54 -05:00
Alex Kavanagh f8986150ab Add xena bundles
- add non-voting focal-xena bundle
- add non-voting impish-xena bundle
- remove groovy-victoria bundle
- align bundles and tests.yaml with designate charm mainly
  to allow test_nrpe_configured to be successful
- rebuild to pick up charm-helpers changes
- update tox/pip.sh to ensure setuptools<50.0.0

Change-Id: I4ba5af13097661bbd4966891c6628abf8a425659
Co-authored-by: Aurelien Lourot <aurelien.lourot@canonical.com>
2021-10-05 13:37:34 +01:00
Aurelien Lourot cfa81adfde Sync release-tools
In order to fix ResolutionImpossible on tox invocation.

https://github.com/openstack-charmers/release-tools/issues/151
https://github.com/openstack-charmers/release-tools/pull/152

Change-Id: Ib0398e33f2c629208ccf7f3323ad92626d791942
2021-07-22 14:53:58 +02:00
Alex Kavanagh 2d0221fa60 21.04 libraries freeze for charms on master branch
* charm-helpers sync for classic charms
* build.lock file for reactive charms
* ensure tox.ini is from release-tools
* ensure requirements.txt files are from release-tools
* On reactive charms:
  - ensure stable/21.04 branch for charms.openstack
  - ensure stable/21.04 branch for charm-helpers

Change-Id: Iec68b0bda37b2139a9c8a2acdd59b3725e11b4cd
2021-04-03 20:24:26 +01:00
Alex Kavanagh dda8a0dff8 Updates to pin charm-tools to 2.8.3
* Update requirements.txt to pin charm-tools to 2.8.3
* Update tox.ini to change the build parameters.
* This upgrades from <2.7 which adds reproducible charms
* Bug was fixed that controlled the default output directory
  doesn't get 'builds' appended.  The tox change puts it
  back so that stable & master both build to the same
  directory.  This may be reviewed in the future.

Change-Id: If01db0736923dea0885c0fe6aa950a617d077750
2021-02-17 12:10:01 +00:00
Alex Kavanagh 0670dc08fa Sync libraries & common files prior to freeze
* charm-helpers sync for classic charms
* charms.ceph sync for ceph charms
* rebuild for reactive charms
* sync tox.ini files as needed
* sync requirements.txt files to sync to standard

Change-Id: I6c087653ed08ce17add35829a8c2f05a7f6837c9
2020-09-26 18:32:26 +01:00
Alex Kavanagh c72f509c0c Release sync for 20.08
- Classic charms: sync charm-helpers.
- Classic ceph based charms:  also sync charms.ceph
- Reactive charms: trigger a rebuild
- sync tox.ini
- sync requirements.txt and test-requirements.txt

Change-Id: Ia3edbe7fbf491218ecd3279179dd2c16ba390da0
2020-07-27 20:52:00 +01:00
Ryan Beisner c0a11631c5
Sync charm/ceph helpers, tox, and requirements
Change-Id: Ibe1505641a4983c046a3893fad9554a88c9beee9
2019-10-01 12:58:02 -05:00
Camille Rodriguez 703e00dc8f Add disco-stein bundle to gate tests
The bundle disco-stein was in the dev bundles because
a bug with the Python 3.7 syntax prevented the success of
the deployment of HA clusters. This bug is fixed, we can
reintegrate disco-stein in the gate bundles.

Other small additions:
- removing sitepackages in tox.ini to avoid test env pollution
- skip_missing_interpreters in tox.ini set to False to avoid false
positives by skipping missing interpreters.

LP Related-Bug: #1823718
Change-Id: I9a106c17947055aa080fbea022d1abb4bd75f2b1
2019-09-04 14:49:39 -04:00
Corey Bryant 0b2f04e182 Add Python 3 Train unit tests
This is a mechanically generated patch to ensure unit testing is in place
for all of the Tested Runtimes for Train.

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

Note that python35-charm-jobs is retained since this charm is supported
on Xenial.

Change-Id: I4946650ee49b6d3409518cec618a650a64274022
Story: #2005924
Task: #34228
2019-07-30 10:19:24 -04:00
Pete Vander Giessen 69226ac8cc Replace ostestr with stestr in testing framework.
A system upgrade broke ostestr. We can fix it by just calling stestr
directly.

Change-Id: Ifebbbe5714854ab3afb55a2f744229600f139e4a
2019-03-07 17:11:09 -05:00
Paul Goins 43161d069b Added tox environment for gathering coverage
This technique was borrowed from the tox "cover" environment in
openstack/nova's tox.ini.  This leverages the fact that stestr lets
you override the python executable via the PYTHON environment
variable.  Doing this allows us to easily generate coverage for our
unit tests.

An important caveat is that this does not provide any coverage for
tests via zaza, amulet, etc.  It is purely focused on the unit tests.

Note that this replaces the previous .coveragerc; coverage
configuration is instead pulled from tox.ini.

Change-Id: Ib364cfe8dc40f0795a2ceaf7513af3bc21811bf6
2019-03-01 14:39:13 +01:00
Doug Hellmann 011952f510 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: I663739e2be72e32101764cbccc9713f1f9ba303a
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-10-23 13:51:33 +02:00
Zuul 3f1154277e Merge "Update links in README" 2018-07-12 16:58:55 +00:00
Nguyen Van Duc 390da097fc 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: If7774c442ac8de0661032bc3b50b422d73bdb440
2018-07-12 17:54:29 +07:00
XiaojueGuan 421dc854ac Update links in README
Change the outdated links to the latest links in README

Change-Id: I56438a947dd76f4e6767157b09ee98c2feb9c295
2018-06-12 16:22:21 +08:00
Ryan Beisner 0411028baa Update tox.ini for py27 requirement
Reactive source charms are Python3-only, but have py27 unit tests
declared in project-config.

The Tox tool recently changed behavior.  It used to pass when a tox
target was missing commands.  Now it fails in that case.

This commit places a py27 no-op shim to allow gate tests to pass,
effectively restoring the original behavior for these py3x-only repos.

Change-Id: Ia3e7be0bf9ac085c66ce318f283f42b0c7cc73fe
Partial-Bug: 1642981
2016-11-28 18:21:12 -06:00
Ryan Beisner f553903d96 Update tox.ini files based on release-tools gold copy
This charm cannot currently use the gold tox.ini files
because the pep8 section requires python 3.  Will need
to maintain this separately/manually until another
approach is determined to work.

Change-Id: I424d19d38668979ed1f572be2d4f6113d51150ef
2016-09-08 23:04:05 +00:00
Ryan Beisner 021c2a609c Add .gitreview and clean up repo
Add src/README.md placeholder to prevent inheritence of the
base layer's readme file in the built charm.

Use the official charms.openstack repo in test-requirements.txt.

Use official designate charm location in the Amulet tests.

Remove upload-and-publish so as not to encourage out-of-band
pushing and publishing.  That is handled by CI.

Remove legacy Makefile.

Rename Amulet test files and drop Icehouse on the Trusty target.

Update tox.ini for Amulet environment variables.

Update metadata.yaml, removing EOL release and adding tags.

Fix apt_pkg mock

Disable py27 unit tests

Change-Id: I5220b73eb41e42cb03e6dac27525140fb21ca449
2016-07-22 14:53:32 +00:00
Liam Young c73067bf5b Add missing docstrings and move pep8 to run in python3 venv 2016-07-11 08:47:10 +00:00
Liam Young 51b9f62307 Add unit tests 2016-07-08 12:35:52 +01:00
Liam Young c0bd441dec Add zone sync code£ 2016-07-02 14:15:09 +00:00
James Page 421e8a18e3 Fixup tox for no tests 2016-02-11 12:15:26 +00:00
James Page 3fb2950ca9 Initial charm 2016-02-11 10:05:16 +00:00