]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa: make sure "rados cppool" requires --yes-i-really-mean-it for RBD
authorIlya Dryomov <idryomov@gmail.com>
Thu, 23 Nov 2023 19:24:24 +0000 (20:24 +0100)
committerIlya Dryomov <idryomov@gmail.com>
Fri, 29 Dec 2023 11:41:12 +0000 (12:41 +0100)
Safeguards in rados CLI tool isn't really the subject of this test, but
it fits nicely.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit 2b135a2eb60e0dd5ab22d213d3d2435608c6a9d3)

qa/workunits/mon/rbd_snaps_ops.sh

index eb88565eab9c2308d88cf17b681f998bcd9410f6..0e5b16b7b80b4a0ebc212c85a1d8bdcfd39b70df 100755 (executable)
@@ -36,6 +36,7 @@ expect 'rbd --pool=test snap ls image' 0
 expect 'rbd --pool=test snap rm image@snapshot' 0
 
 expect 'ceph osd pool mksnap test snapshot' 22
+expect 'rados -p test mksnap snapshot' 1
 
 expect 'ceph osd pool delete test test --yes-i-really-really-mean-it' 0
 
@@ -52,6 +53,8 @@ expect 'rbd --pool test-foo snap create image@snapshot' 0
 ceph osd pool delete test-bar test-bar --yes-i-really-really-mean-it || true
 expect 'ceph osd pool create test-bar 8' 0
 expect 'ceph osd pool application enable test-bar rbd'
+# "rados cppool" without --yes-i-really-mean-it should fail
+expect 'rados cppool test-foo test-bar' 1
 expect 'rados cppool test-foo test-bar --yes-i-really-mean-it' 0
 expect 'rbd --pool test-bar snap rm image@snapshot' 95
 expect 'ceph osd pool delete test-foo test-foo --yes-i-really-really-mean-it' 0