def test_runner_ascii(patched_func): cmd = ['cat', os.path.join(TEST_DIR,'ascii_text.txt')] for line in run_command(cmd): if type(line) == int: assert_eq(line, 0) else: assert_eq(line.rstrip(), 'Hello ASCII!')
def test_runner_ascii(patched_func): cmd = ['cat', os.path.join(TEST_DIR, 'ascii_text.txt')] for line in run_command(cmd): if type(line) == int: assert_eq(line, 0) else: assert_eq(line.rstrip(), 'Hello ASCII!')
def test_runner_unicode(patched_func): cmd = ['cat', os.path.join(TEST_DIR,'unicode_text.txt')] for line in run_command(cmd): if type(line) == int: assert_eq(line, 0) else: if line.rstrip() != 'Hello Unicode\u203d': print('WARNING: Unicode reading not supported!')
def test_runner_unicode(patched_func): cmd = ['cat', os.path.join(TEST_DIR, 'unicode_text.txt')] for line in run_command(cmd): if type(line) == int: assert_eq(line, 0) else: if line.rstrip() != 'Hello Unicode\u203d': print('WARNING: Unicode reading not supported!')