示例#1
0
 def test_show_help(self):
     dist = Distribution()
     sys.argv = []
     dist.help = 1
     dist.script_name = 'setup.py'
     with captured_stdout() as s:
         dist.parse_command_line()
     output = [ line for line in s.getvalue().split('\n') if line.strip() != '' ]
     self.assertTrue(output)
示例#2
0
 def test_show_help(self):
     dist = Distribution()
     sys.argv = []
     dist.help = 1
     dist.script_name = 'setup.py'
     with captured_stdout() as s:
         dist.parse_command_line()
     output = [
         line for line in s.getvalue().split('\n') if line.strip() != ''
     ]
     self.assertTrue(output)
示例#3
0
    def test_show_help(self):
        # smoke test, just makes sure some help is displayed
        dist = Distribution()
        sys.argv = []
        dist.help = 1
        dist.script_name = "setup.py"
        with captured_stdout() as s:
            dist.parse_command_line()

        output = [line for line in s.getvalue().split("\n") if line.strip() != ""]
        self.assertTrue(len(output) > 0)
示例#4
0
    def test_show_help(self):
        # smoke test, just makes sure some help is displayed
        self.addCleanup(log.set_threshold, log._global_log.threshold)
        dist = Distribution()
        sys.argv = []
        dist.help = 1
        dist.script_name = 'setup.py'
        with captured_stdout() as s:
            dist.parse_command_line()

        output = [line for line in s.getvalue().split('\n')
                  if line.strip() != '']
        self.assertTrue(output)