diff --git a/plugin/documents.py b/plugin/documents.py index b944f1323..492ab43d8 100644 --- a/plugin/documents.py +++ b/plugin/documents.py @@ -56,6 +56,7 @@ from .session_view import SessionView from functools import partial from functools import wraps +from os.path import basename from typing import Any, Callable, Generator, Iterable, TypeVar from typing import cast from typing_extensions import Concatenate, ParamSpec @@ -95,6 +96,10 @@ def is_regular_view(v: sublime.View) -> bool: return False if v.settings().get('is_widget'): return False + # Not a syntax test file. + if (filename := v.file_name()) and basename(filename).startswith('syntax_test_'): + return False + # Not a transient sheet (preview). sheet = v.sheet() if not sheet: return False