class TestBasic:
- def test_non_ascii_in_non_options(self):
- # unicode() is not able to convert this str parameter into unicode
- # using the default encoding 'ascii'. and validate_command() should
- # not choke on it.
- assert_is_none(validate_command(sigdict, ['章鱼和鱿鱼']))
+ def test_non_ascii_in_non_options(self):
+ # unicode() is not able to convert this str parameter into unicode
+ # using the default encoding 'ascii'. and validate_command() should
+ # not choke on it.
+ assert_is_none(validate_command(sigdict, ['章鱼和鱿鱼']))
class TestPG(TestArgparse):
'rename-bucket']))
assert_equal({}, validate_command(sigdict, ['osd', 'crush',
'rename-bucket',
- 'srcname']))
+ 'srcname']))
assert_equal({}, validate_command(sigdict, ['osd', 'crush',
'rename-bucket', 'srcname',
'dstname',
def test_crush_tunables(self):
for tunable in ('legacy', 'argonaut', 'bobtail', 'firefly',
- 'optimal', 'default'):
+ 'optimal', 'default'):
self.assert_valid_command(['osd', 'crush', 'tunables',
tunable])
assert_equal({}, validate_command(sigdict, ['osd', 'crush',
'poolname',
'128', '128',
'erasure', '^^^',
- 'ruleset']))
+ 'ruleset']))
assert_equal({}, validate_command(sigdict, ['osd', 'pool', 'create',
'poolname',
'128', '128',
'erasure', 'profile',
'ruleset',
- 'toomany']))
+ 'toomany']))
assert_equal({}, validate_command(sigdict, ['osd', 'pool', 'create',
'poolname',
'128', '128',
def test_reweight_by_utilization(self):
self.assert_valid_command(['osd', 'reweight-by-utilization'])
self.assert_valid_command(['osd', 'reweight-by-utilization', '100'])
- self.assert_valid_command(['osd', 'reweight-by-utilization', '100', '.1'])
+ self.assert_valid_command(['osd', 'reweight-by-utilization', '100', '.1'])
self.assert_valid_command(['osd', 'reweight-by-utilization', '--no-increasing'])
assert_equal({}, validate_command(sigdict, ['osd',
'reweight-by-utilization',