INNER CODE UNIT · Python

FuseGMockAllCcToFile

Squirrel-Engine/Squirrel-Engine · googletest/googlemock/scripts/fuse_gmock_files.py:159

def FuseGMockAllCcToFile(gmock_root, output_file):
  """Scans folder gmock_root to fuse gmock-all.cc into output_file."""

  processed_files = sets.Set()

  def ProcessFile(gmock_source_file):
    """Processes the given gmock source file."""

    # We don't process the same #included file twice.
    if gmock_source_file in processed_files:
      return

    processed_files.add(gmock_source_file)

    # Reads each line in the given gmock source file.
    for line in file(os.path.join(gmock_root, gmock_source_file), 'r'):
      m = INCLUDE_GMOCK_FILE_REGEX.match(line)
      if m:

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…