Conditions | 9 |
Total Lines | 27 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | # pylint: disable=unused-variable,expression-not-assigned,misplaced-comparison-constant,singleton-comparison |
||
11 | def describe_font(): |
||
12 | |||
13 | @pytest.fixture |
||
14 | def font(): |
||
15 | return Font(Path('mock_dir', 'FooBar.otf')) |
||
16 | |||
17 | def describe_str(): |
||
18 | |||
19 | def is_based_on_name(font): |
||
20 | expect(str(font)) == 'foobar' |
||
21 | |||
22 | def describe_bool(): |
||
23 | |||
24 | def is_based_on_default(font): |
||
25 | expect(bool(font)) == True |
||
26 | |||
27 | font.DEFAULT = 'foobar' |
||
28 | expect(bool(font)) == False |
||
29 | |||
30 | def describe_name(): |
||
31 | |||
32 | def is_derived_from_filename(font): |
||
33 | expect(font.name) == 'foobar' |
||
34 | |||
35 | def it_replaces_underscores(font): |
||
36 | font.path = Path('a_b') |
||
37 | expect(font.name) == 'a-b' |
||
38 |