コード例 #1
0
    def test_show_formats(self):
        with captured_stdout() as stdout:
            show_formats()

        # the output should be a header line + one line per format
        num_formats = len(ARCHIVE_FORMATS.keys())
        output = [line for line in stdout.getvalue().split("\n") if line.strip().startswith("--formats=")]
        self.assertEqual(len(output), num_formats)
コード例 #2
0
ファイル: teststest_sdist.py プロジェクト: kusaku/wot_scripts
 def test_show_formats(self):
     with captured_stdout() as stdout:
         show_formats()
     num_formats = len(ARCHIVE_FORMATS.keys())
     output = [
         line for line in stdout.getvalue().split('\n')
         if line.strip().startswith('--formats=')
     ]
     self.assertEqual(len(output), num_formats)
コード例 #3
0
ファイル: test_sdist.py プロジェクト: webiumsk/WOT-0.9.15.1
 def test_show_formats(self):
     with captured_stdout() as stdout:
         show_formats()
     num_formats = len(ARCHIVE_FORMATS.keys())
     output = [ line for line in stdout.getvalue().split('\n') if line.strip().startswith('--formats=') ]
     self.assertEqual(len(output), num_formats)