From 26ab77bdf6994b8a160d93db53eab2656163923b Mon Sep 17 00:00:00 2001 From: Andrej730 Date: Mon, 3 Aug 2026 15:38:55 +0500 Subject: [PATCH] rule fixtures: script to regenerate all fixtures --- .../test/fixtures/rules/generate.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 src/ifcopenshell-python/test/fixtures/rules/generate.py diff --git a/src/ifcopenshell-python/test/fixtures/rules/generate.py b/src/ifcopenshell-python/test/fixtures/rules/generate.py new file mode 100644 index 0000000000..9dc7a6d684 --- /dev/null +++ b/src/ifcopenshell-python/test/fixtures/rules/generate.py @@ -0,0 +1,13 @@ +import subprocess +import sys +from pathlib import Path + +directory = Path(__file__).parent + +if __name__ == "__main__": + for path in directory.glob("*.ifc"): + path.unlink() + + for path in sorted(directory.glob("generate_*.py")): + print(f"=== {path.name} ===") + subprocess.run([sys.executable, str(path)], cwd=directory, check=True)