Skip to content
Myr

test_format_filename.py

This file

Path

tests/test_utils/test_format_filename.py

9 lines · 383 bytes · Python

Last changed by

Merge stable into main. (#3674)Rowlando13before adoption7925a34

History of this file

Take it

Merge stable into main. (#3674)Rowlando13before adoption7925a34

lines 1–9why, one step back
1import click
234def test_filename_formatting():5 assert click.format_filename(b"foo.txt") == "foo.txt"6 assert click.format_filename(b"/x/foo.txt") == "/x/foo.txt"7 assert click.format_filename("/x/foo.txt") == "/x/foo.txt"8 assert click.format_filename("/x/foo.txt", shorten=True) == "foo.txt"9 assert click.format_filename("/x/\ufffd.txt", shorten=True) == "�.txt"