feat: named case-result load combinations with full GUI support
Snapshots the current development tree, headlined by proper load combinations (user request): a reusable LoadCombination entity of weighted completed static-case results (e.g. 1.2xDead + 1.6xLive). - core: LoadCombination/LoadCombinationItem entities, Project integration (lookup, unique ids, reference validation) - services: combinations.py (linear superposition + envelope), exported via services __init__ - commands: undoable Add/Delete/Update for combinations - GUI: Load Combinations manager dialog, Run-dialog evaluation, envelope display in Results panel, Combinations tab in Table dock - tests: unit coverage (validation, math, error paths) + integration superposition check vs a single factored run
This commit is contained in:
commit
f361fee969
560 changed files with 178701 additions and 0 deletions
30
tests/conftest.py
Normal file
30
tests/conftest.py
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
"""Shared pytest configuration.
|
||||
|
||||
The GUI suite is headless by default: unless the caller already chose a
|
||||
platform, ``QT_QPA_PLATFORM=offscreen`` is set here, before pytest-qt
|
||||
builds its session ``QApplication``. An explicit caller value is respected.
|
||||
|
||||
OpenseesPy is a process-global singleton, so a lazy autouse guard wipes the
|
||||
domain after every test. The import is inside the teardown so that
|
||||
``tests/unit`` never imports the solver.
|
||||
"""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import os
|
||||
from collections.abc import Iterator
|
||||
|
||||
import pytest
|
||||
|
||||
os.environ.setdefault("QT_QPA_PLATFORM", "offscreen")
|
||||
|
||||
|
||||
@pytest.fixture(autouse=True)
|
||||
def _wipe_opensees_domain() -> Iterator[None]:
|
||||
"""Wipe the OpenseesPy domain after a test if the solver was imported."""
|
||||
yield
|
||||
try:
|
||||
from openseespy.opensees import wipe
|
||||
except Exception: # pragma: no cover - solver not installed / import side effects
|
||||
return
|
||||
wipe()
|
||||
Loading…
Reference in a new issue