Kill the mutants that survived on the lines the release review changed
This commit is contained in:
@@ -119,6 +119,18 @@ class TmuxEffect(unittest.TestCase):
|
||||
pathlib.Path(folder, "tmux").write_text(f"#!{sys.executable}\nimport sys\nsys.stdout.buffer.write(b'caf\\xe9')\n")
|
||||
self.assertEqual(effects.tmux(["list-windows"]).stdout, "caf\ufffd")
|
||||
|
||||
def test_runs_tmux_without_this_processs_input(self):
|
||||
with tempfile.TemporaryDirectory() as folder:
|
||||
effects = self.fake_tmux(folder)
|
||||
pathlib.Path(folder, "tmux").write_text(f"#!{sys.executable}\nimport sys\nprint(repr(sys.stdin.read()))\n")
|
||||
pathlib.Path(folder, "typed").write_text("what the human types\n")
|
||||
kept = os.dup(0)
|
||||
self.addCleanup(os.close, kept)
|
||||
self.addCleanup(os.dup2, kept, 0)
|
||||
with open(pathlib.Path(folder, "typed")) as typed:
|
||||
os.dup2(typed.fileno(), 0)
|
||||
self.assertEqual(effects.tmux(["list-windows"]).stdout, "''\n")
|
||||
|
||||
def test_reads_a_tmux_that_cannot_start_as_exit_127(self):
|
||||
with tempfile.TemporaryDirectory() as folder:
|
||||
done = system_effects(pathlib.Path.home(), os.environ | {"PATH": folder}).tmux(["-V"])
|
||||
|
||||
Reference in New Issue
Block a user