From: Loic Dachary Date: Sun, 22 Dec 2013 17:26:42 +0000 (+0100) Subject: mon: s/rep/replicated/ in pool create prototype X-Git-Tag: v0.75~49^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F983%2Fhead;p=ceph.git mon: s/rep/replicated/ in pool create prototype The test is updated to remove unecessary asserts. Since all combinations of properties and pool type are allowed, there is no way to statically check the validity of the arguments. Signed-off-by: Loic Dachary --- diff --git a/src/mon/MonCommands.h b/src/mon/MonCommands.h index 79505f256c32..8c08030f2148 100644 --- a/src/mon/MonCommands.h +++ b/src/mon/MonCommands.h @@ -496,7 +496,7 @@ COMMAND("osd pool create " \ "name=pool,type=CephPoolname " \ "name=pg_num,type=CephInt,range=0 " \ "name=pgp_num,type=CephInt,range=0,req=false " \ - "name=pool_type,type=CephChoices,strings=rep|erasure,req=false " \ + "name=pool_type,type=CephChoices,strings=replicated|erasure,req=false " \ "name=properties,type=CephString,n=N,req=false,goodchars=[A-Za-z0-9-_.=]", \ "create pool", "osd", "rw", "cli,rest") COMMAND("osd pool delete " \ diff --git a/src/test/pybind/test_ceph_argparse.py b/src/test/pybind/test_ceph_argparse.py index fdfd726d4000..fbd0b431419a 100755 --- a/src/test/pybind/test_ceph_argparse.py +++ b/src/test/pybind/test_ceph_argparse.py @@ -886,30 +886,7 @@ class TestOSD(TestArgparse): 'poolname', '128', '128']) self.assert_valid_command(['osd', 'pool', 'create', 'poolname', '128', '128', - 'foo=bar']) - self.assert_valid_command(['osd', 'pool', 'create', - 'poolname', '128', '128', - 'foo=bar', 'baz=frob']) - self.assert_valid_command(['osd', 'pool', 'create', - 'poolname', '128', - 'foo=bar', 'baz=frob']) - self.assert_valid_command(['osd', 'pool', 'create', - 'poolname', '128', '128', - 'rep']) - self.assert_valid_command(['osd', 'pool', 'create', - 'poolname', '128', '128', - 'raid4']) - self.assert_valid_command(['osd', 'pool', 'create', - 'poolname', '128', '128', - 'erasure']) - self.assert_valid_command(['osd', 'pool', 'create', - 'poolname', '128', '128', - 'rep', - 'foo=bar']) - self.assert_valid_command(['osd', 'pool', 'create', - 'poolname', '128', '128', - 'rep', - 'foo=bar', 'bar=baz']) + 'whatever']) assert_equal({}, validate_command(sigdict, ['osd', 'pool', 'create'])) assert_equal({}, validate_command(sigdict, ['osd', 'pool', 'create', 'poolname']))