Skip to content

Commit

Permalink
runtest: ignore Emacs lock files (.#XXX)
Browse files Browse the repository at this point in the history
  • Loading branch information
strub committed Jan 17, 2025
1 parent 2194cd8 commit fc44784
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion scripts/testing/runtest
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,10 @@ class Gather:
return True
return False

@staticmethod
def is_file_statically_ignored(src):
return os.path.basename(src).startswith('.#')

@classmethod
def gather(cls, obj):
try:
Expand Down Expand Up @@ -376,7 +380,11 @@ class Gather:
dirs = map(cls.gather, dirs)

files = list(itertools.chain.from_iterable(dirs))
files = [x for x in files if not cls.is_file_excluded(x.filename, scenario.fexclude)]
files = [
x for x in files if
not cls.is_file_statically_ignored(x.filename) and
not cls.is_file_excluded(x.filename, scenario.fexclude)
]

return files

Expand Down

0 comments on commit fc44784

Please sign in to comment.