~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_options.py

Merge pt1 hooks branch.

Show diffs side-by-side

added added

removed removed

Lines of Context:
396
396
        self.assertTrue(format.is_hidden('hidden'))
397
397
        self.assertFalse(format.is_hidden('visible'))
398
398
 
 
399
    def test_short_name(self):
 
400
        registry = controldir.ControlDirFormatRegistry()
 
401
        opt = option.RegistryOption('format', help='', registry=registry)
 
402
        self.assertEquals(None, opt.short_name())
 
403
        opt = option.RegistryOption('format', short_name='F', help='',
 
404
            registry=registry)
 
405
        self.assertEquals('F', opt.short_name())
 
406
 
399
407
    def test_option_custom_help(self):
400
408
        the_opt = option.Option.OPTIONS['help']
401
409
        orig_help = the_opt.help[:]