code: def expand_filename_pattern(self, pattern, base_dir, sourcefile=None):
          
  
          # replace vars like ${benchmark_path},
          # with converting to list and back, we can use the function 'substitute_vars()'
          expandedPattern = substitute_vars([pattern], self, sourcefile)
          assert len(expandedPattern) == 1
          expandedPattern = expandedPattern[0]
  
          if expandedPattern != pattern:
              logging.debug("Expanded variables in expression %r to %r.",
                            pattern, expandedPattern)
  
          fileList = util.expand_filename_pattern(expandedPattern, base_dir)
  
          # sort alphabetical,
          fileList.sort()
  
          if not fileList:
              logging.warning("No files found matching %r.", pattern)
  
          return fileList
docs: The function expand_filename_pattern expands a filename pattern to a sorted list
          of filenames. The pattern can contain variables and wildcards.
          If base_dir is given and pattern is not absolute, base_dir and pattern are joined.