Path: blob/main/tests/netedit/scripts/updateTestsuiteFiles.py
193874 views
#!/usr/bin/env python1# Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.dev/sumo2# Copyright (C) 2025-2026 German Aerospace Center (DLR) and others.3# This program and the accompanying materials are made available under the4# terms of the Eclipse Public License 2.0 which is available at5# https://www.eclipse.org/legal/epl-2.0/6# This Source Code may also be made available under the following Secondary7# Licenses when the conditions for such availability set forth in the Eclipse8# Public License 2.0 are satisfied: GNU General Public License, version 29# or later which is available at10# https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html11# SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later1213# @file updateTestsuiteFiles.py14# @author Pablo Alvarez Lopez15# @date 2025-12-051617import os1819if __name__ == "__main__":20target_files = [21"testsuite.netedit.external",22"testsuite.netedit.internal",23"testsuite.neteditoutput"24]2526current_dir = os.path.dirname(os.path.abspath(__file__))27base_dir = os.path.normpath(os.path.join(current_dir, '..'))2829print(f"Starting scan in: {base_dir}")3031for root, dirs, files in os.walk(base_dir):32dirs[:] = [d for d in dirs if not d.startswith('.') and d != 'scripts' and d != '__pycache__']33dirs.sort()3435if dirs:36for filename in target_files:37file_path = os.path.join(root, filename)38print(f"Updating {filename} in {root}")39with open(file_path, 'w') as f:40f.write("\n\n".join(dirs) + "\n")414243