# Path: pre_commit_hooks/fix_byte_order_marker.py
# def main(argv: Sequence[str] | None = None) -> int:


from pre_commit_hooks import fix_byte_order_marker
from __future__ import annotations



def test_failure(tmpdir):
    f = tmpdir.join('f.txt')
    f.write_text('ohai', encoding='utf-8-sig')

# Path: pre_commit_hooks/fix_byte_order_marker.py
# def main(argv: Sequence[str] | None = None) -> int:


# Path: tests/fix_byte_order_marker_test.py
from pre_commit_hooks import fix_byte_order_marker

from __future__ import annotations



def test_failure(tmpdir):
    f = tmpdir.join('f.txt')
    f.write_text('ohai', encoding='utf-8-sig')

    assert fix_byte_order_marker.main((str(f),)) == 1