mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-08 14:18:26 +02:00
Refactor scoring
This commit is contained in:
@@ -31,6 +31,7 @@ class Selection(BaseTest):
|
||||
has_source_code_vf = has('sourcecodeVf')
|
||||
has_fira_code = has('Fira Code')
|
||||
has_hack = has('Hack')
|
||||
has_operator_mono = has('Operator Mono')
|
||||
del fonts_map, has
|
||||
|
||||
def s(family: str, *expected: str) -> None:
|
||||
@@ -52,6 +53,8 @@ class Selection(BaseTest):
|
||||
both('fira code', 'FiraCodeRoman-Regular', 'FiraCodeRoman-SemiBold', 'FiraCodeRoman-Regular', 'FiraCodeRoman-SemiBold')
|
||||
if has_hack:
|
||||
both('hack', 'Hack-Regular', 'Hack-Bold', 'Hack-Italic', 'Hack-BoldItalic')
|
||||
if has_operator_mono:
|
||||
both('operator mono', 'Hack-Regular', 'Hack-Bold', 'Hack-Italic', 'Hack-BoldItalic')
|
||||
|
||||
|
||||
class Rendering(BaseTest):
|
||||
|
||||
@@ -308,9 +308,14 @@ def env_for_python_tests(report_env: bool = False) -> Iterator[None]:
|
||||
print('Python:', python_for_type_check())
|
||||
from kitty.fast_data_types import has_avx2, has_sse4_2
|
||||
print(f'Intrinsics: {has_avx2=} {has_sse4_2=}')
|
||||
# we need fonts installed in the user home directory as well, so initialize
|
||||
# fontconfig before nuking $HOME and friends
|
||||
from kitty.fonts.common import all_fonts_map
|
||||
all_fonts_map(True)
|
||||
|
||||
with TemporaryDirectory() as tdir, env_vars(
|
||||
HOME=tdir,
|
||||
KT_ORIGINAL_HOME=os.path.expanduser('~'),
|
||||
USERPROFILE=tdir,
|
||||
PATH=path,
|
||||
TERM='xterm-kitty',
|
||||
|
||||
Reference in New Issue
Block a user