def test_get_command_output_returns_sequence_of_lines(self): self.assertEqual(["1", "2"], address.get_command_output("echo", "1\n2"))
def test_get_command_output_uses_C_locale(self): locale = parse_locale_lines(address.get_command_output("locale")) self.assertEqual("C.UTF-8", locale["LC_CTYPE"]) self.assertEqual("C.UTF-8", locale["LC_MESSAGES"]) self.assertEqual("C.UTF-8", locale["LANG"])
def test_get_command_output_executes_command(self): self.assertEqual(["Hello"], address.get_command_output("echo", "Hello"))
def test_get_command_output_does_not_expand_arguments(self): self.assertEqual(["$*"], address.get_command_output("echo", "$*"))
def test_get_command_output_returns_sequence_of_lines(self): self.assertEqual(['1', '2'], address.get_command_output('echo', '1\n2'))
def test_get_command_output_uses_C_locale(self): locale = parse_locale_lines(address.get_command_output('locale')) self.assertEqual('C.UTF-8', locale['LC_CTYPE']) self.assertEqual('C.UTF-8', locale['LC_MESSAGES']) self.assertEqual('C.UTF-8', locale['LANG'])
def test_get_command_output_executes_command(self): self.assertEqual(["Hello"], address.get_command_output('echo', 'Hello'))
def test_get_command_output_uses_C_locale(self): locale = parse_locale_lines(address.get_command_output('locale')) self.assertEqual('C', locale['LC_CTYPE']) self.assertEqual('C', locale['LC_MESSAGES']) self.assertEqual('en_US.UTF-8', locale['LANG'])
def test_get_command_output_returns_sequence_of_lines(self): self.assertEqual( ['1', '2'], address.get_command_output('echo', '1\n2'))
def test_get_command_output_does_not_expand_arguments(self): self.assertEqual(["$*"], address.get_command_output('echo', '$*'))
def test_get_command_output_executes_command(self): self.assertEqual( ["Hello"], address.get_command_output('echo', 'Hello'))