コード例 #1
0
 def test_no_css_option(self):
     """Simple test for --no-css option"""
     f1 = self.write_file("foobar")
     f2 = self.write_file("foobarbaz")
     out = io.BytesIO()
     ghdiff.main([f1, f2, "--no-css"], stdout=out)
     output = out.getvalue()
     self.assertFalse(b"<style" in output)
コード例 #2
0
ファイル: tests.py プロジェクト: kilink/ghdiff
 def test_no_css_option(self):
     """Simple test for --no-css option"""
     f1 = self.write_file("foobar")
     f2 = self.write_file("foobarbaz")
     out = io.BytesIO()
     ghdiff.main([f1, f2, "--no-css"], stdout=out)
     output = out.getvalue()
     self.assertFalse(b"<style" in output)
コード例 #3
0
 def test_script(self):
     """Simple exercise of the commandline mode"""
     f1 = self.write_file("foobar")
     f2 = self.write_file("foobarbaz")
     out = io.BytesIO()
     ghdiff.main([f1, f2], stdout=out)
     output = out.getvalue()
     self.assertTrue(b"-foobar" in output)
     self.assertTrue(b'+foobar<span class="highlight">baz</span>' in output)
コード例 #4
0
ファイル: tests.py プロジェクト: kilink/ghdiff
 def test_script(self):
     """Simple exercise of the commandline mode"""
     f1 = self.write_file("foobar")
     f2 = self.write_file("foobarbaz")
     out = io.BytesIO()
     ghdiff.main([f1, f2], stdout=out)
     output = out.getvalue()
     self.assertTrue(b"-foobar" in output)
     self.assertTrue(b'+foobar<span class="highlight">baz</span>' in output)