Add Subcommand.make_arg_parser() method
				
					
				
			split that out for clarity
This commit is contained in:
		
							parent
							
								
									4641e24afd
								
							
						
					
					
						commit
						ed6a5db452
					
				
					 3 changed files with 30 additions and 5 deletions
				
			
		| 
						 | 
				
			
			@ -169,9 +169,11 @@ class TestCommandArgumentParser(TestCase):
 | 
			
		|||
 | 
			
		||||
class TestSubcommand(TestCase):
 | 
			
		||||
 | 
			
		||||
    def test_run(self):
 | 
			
		||||
    def test_basic(self):
 | 
			
		||||
        cmd = base.Command()
 | 
			
		||||
        subcmd = base.Subcommand(cmd)
 | 
			
		||||
        subcmd.name = 'foobar'
 | 
			
		||||
        self.assertEqual(repr(subcmd), 'Subcommand(name=foobar)')
 | 
			
		||||
        # TODO: this doesn't really test anything per se, but at least
 | 
			
		||||
        # gives us the coverage..
 | 
			
		||||
        subcmd._run()
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue