Files
pre-commit/tests/languages/helpers_test.py
2014-06-20 10:20:02 -07:00

17 lines
420 B
Python

from __future__ import absolute_import
from __future__ import unicode_literals
from pre_commit.languages.helpers import file_args_to_stdin
def test_file_args_to_stdin_empty():
assert file_args_to_stdin([]) == ''
def test_file_args_to_stdin_some():
assert file_args_to_stdin(['foo', 'bar']) == 'foo\0bar\0'
def test_file_args_to_stdin_tuple():
assert file_args_to_stdin(('foo', 'bar')) == 'foo\0bar\0'