Commit Graph

121 Commits

Author SHA1 Message Date
Luciano Lo Giudice 3ab81b4ebb Refresh kernel partition table between tests (#779)
The test suite for ceph-iscsi does a bunch of operations on filesystems
in quick succession, so some tests are prone to fail if the kernel doesn't
update the partition table. This PR does this manually between tests by
calling the 'partprobe' command.

Co-authored-by: Luciano Lo Giudice <luciano.logiudice@canonical.com>
2022-06-09 16:58:37 +02:00
Liam Young 251d6a85a0 Merge pull request #765 from jpnorenam/ceph-auth-actions
Add test for ceph auth actions get-or-create-user and delete-user
2022-06-09 13:00:28 +01:00
Juan Pablo Noreña-Monsalve 0f867b476d update test.py 2022-06-09 06:53:13 -05:00
Juan Pablo Noreña-Monsalve 72e2979901 update test.py 2022-06-09 06:47:47 -05:00
Ethan Myers 9974c3849b no more print 2022-06-02 14:12:05 +00:00
Ethan Myers 197504a728 switched to query ceph daemon vs checking config 2022-05-31 22:03:31 +00:00
Ethan Myers 3719349773 Using retry and better assert 2022-05-27 19:39:24 +00:00
Ubuntu 3c609adde8 Add new ceph-fs configuration test 2022-05-26 19:00:17 +00:00
Juan Pablo Norena 8cba107f3a add test for deleting non-existing user 2022-05-18 11:57:29 +00:00
Juan Pablo Norena a8f71c8e05 Add test for ceph auth actions get-or-create-user and delete-user 2022-05-15 20:13:26 +00:00
Billy Olsen 0d07a39d60 Merge pull request #667 from gnuoy/ceph-radosgw-multi
Add wait for sync to ceph RGW tests
2022-05-10 10:11:28 -07:00
Luciano Lo Giudice 1a5b3f6152 Also wait for the SAML 'enabled' message 2022-05-02 17:31:27 -03:00
Luciano Lo Giudice eaf33ab2bd Add docstring to public method 2022-05-02 14:43:36 -03:00
Luciano Lo Giudice a6846dd161 Add a few retries to avoid race conditions 2022-05-02 14:37:54 -03:00
Luciano Lo Giudice 7d70b22846 PEP8 style fixes 2022-04-29 18:04:15 -03:00
Luciano Lo Giudice d9a2c95cd5 Fix ceph-dashboard SAML tests
This PR ensures that the SAML tests are using a fully valid IDP
metadata (Ceph's dashboard doesn't report its validity until SAML
features are used), as well as using TLS in the requests, in addition
to some cleanups here and there.
2022-04-29 18:00:18 -03:00
Luciano Lo Giudice a7f4e92e02 Reorder storage operation 2022-04-12 21:16:27 -03:00
Luciano Lo Giudice b7bb8597ce Sync kernel partitions 2022-04-12 19:47:43 -03:00
Luciano Lo Giudice f09bc087b3 Setup loop devices early on in the Ceph tests
There appears to be a race condition between the loop device creation
and its actual usage. In order to prevent that, this PR setups these
devices during the test initialization instead of right before using
them in the 'add-disk' tests.
2022-04-12 17:30:25 -03:00
Luciano Lo Giudice b7d7588f46 Test SAML redirect and presence of metadata 2022-04-05 14:50:15 -03:00
Luciano Lo Giudice 99b3cd6dec Use ceph-mon as application 2022-04-04 19:59:43 -03:00
Luciano Lo Giudice d1ad9f7a2a Use an existing application for version fetching 2022-04-04 18:21:31 -03:00
Luciano Lo Giudice 124d16acbb Add test for ceph-dashboard SAML functionality 2022-04-04 15:49:34 -03:00
Luciano Lo Giudice 3a7afecf4d Remove spurious loop device 2022-03-21 19:51:59 -03:00
Luciano Lo Giudice e1d10f9359 Use the correct module 2022-03-21 18:44:42 -03:00
Luciano Lo Giudice 1b01ff2c51 Merge branch 'master' into osd-remove-test 2022-03-21 18:39:59 -03:00
Chris MacNaughton a45db73007 Merge pull request #675 from openstack-charmers/osd-add-disk-test
Osd add disk test
2022-02-22 07:47:52 +00:00
Luciano Lo Giudice 11fa17fc6e Correctly prefix module access 2022-02-17 18:19:49 -03:00
Luciano Lo Giudice ed47cb718a Correctly indent docstring 2022-02-17 18:15:46 -03:00
Luciano Lo Giudice e6d6b9e4b5 Run command on ceph-mon since some versions don't allow ceph-osd for it 2022-02-17 18:12:05 -03:00
Luciano Lo Giudice e751e4a989 Rearrange functions into separate modules 2022-02-10 14:28:50 -03:00
Luciano Lo Giudice c8302161a1 Also test that the new number of OSD's is correct. 2022-01-20 20:47:12 -03:00
Alex Kavanagh 0af4c93d52 Switch unit.public_address to unit.get_public_address()
Due to the bug [1] on OpenStack providers, unit.public_address doesn't
actually work reliably.  The fix [2] is only for the async function
unit.get_public_address().  Sadly, zaza relied on unit.public_address
and so it needs this patch for juju 2.9 support on OpenStack providers.

This patch relies on an associated patch in zaza [3]; thus this will
fails its tests until that passes.

[1]: https://github.com/juju/python-libjuju/issues/551
[2]: https://github.com/juju/python-libjuju/pull/600
[3]: https://github.com/openstack-charmers/zaza/pull/468
2022-01-14 15:21:32 +00:00
Luciano Lo Giudice 4ecea0ee06 Remove unused variable 2021-12-09 19:10:43 -03:00
Luciano Lo Giudice efc30389d6 Implement test for disk replacement
This PR builds on the add-disk one, testing the complete flow
of adding a disk, removing it and finally re-adding it after
recycling the original OSD id.
2021-12-09 19:08:11 -03:00
Luciano Lo Giudice f6a0b14df4 Fix import of juju utilities 2021-11-29 16:00:26 -03:00
Luciano Lo Giudice 7933615a7e Remove unused import 2021-11-29 12:09:28 -03:00
Luciano Lo Giudice 97f1ea5693 Move functions into juju utilities. 2021-11-29 12:08:28 -03:00
Luciano Lo Giudice 4a52ba1dba Add docstrings. 2021-11-26 18:40:14 -03:00
Luciano Lo Giudice a7865afb64 Test the enhancements of the 'add-disk' action for ceph-osd
This PR tests that a new device is succesfully added to the OSD
charm, and that it's done so via the 'bcache' mechanism. The
backing storage is provided via a loopback device, whereas the
caching storage is provided by Juju itself.
2021-11-26 18:29:29 -03:00
Liam Young 7f7b4f0dc7 Add wait for sync to ceph RGW tests 2021-11-10 14:35:54 +00:00
Corey Bryant 11f956b81b Skip failing ceph test
Skip test_ceph_pool_creation_with_text_file for releases >= victoria
until the issue is properly fixed.

This works around issue #647
2021-11-03 21:24:45 +00:00
Liam Young d689fb91fc Add retries when accessing Ceph dashboard (#646) 2021-10-04 12:16:43 +01:00
Liam Young 6918f9ebb3 Extend Ceph Dashboards tests to check ceph services are registered (#643) 2021-10-03 16:13:50 +01:00
James Page 66b1c35d94 Merge pull request #631 from gnuoy/ceph-dash-grafana-url
Add setup method for setting grafana api for ceph dashboard
2021-09-13 10:47:02 +01:00
Liam Young 23f95655b9 Add setup method for setting grafana api for ceph dashboard 2021-09-08 17:44:11 +00:00
Liam Young 36d85aece5 Pacific requires client to set accepted api version 2021-09-08 13:34:30 +00:00
Liam Young 5993f3f2c5 Dashboard test updates
Verify CA now that bug is fix released *1.
Check logging in to the dashbaord works
Use a random username for tests so a test reruns work.

*1 https://bugs.launchpad.net/cloud-archive/+bug/1933410
2021-09-06 12:17:41 +00:00
Liam Young 5baf16237f Add certificate check for Ceph dashboard
Add setup step for the dashboard which will block until the
certificates are present and the model is idle. This is to prevent
the tests from continuing when the certificates are not ready.
Also up CephDashboardTest to use standard tools for collecting
ca cert.
2021-08-31 17:24:15 +00:00
Liam Young 7cec6a27b5 Fix doc string 2021-06-24 11:57:21 +00:00