fix(landing-page): Bundle-relative Pfade fuer Reports, cppcheck-Step vor landing-page
This commit is contained in:
@@ -87,15 +87,15 @@ jobs:
|
|||||||
- name: Doxygen API-Dokumentation
|
- name: Doxygen API-Dokumentation
|
||||||
run: make docs
|
run: make docs
|
||||||
|
|
||||||
- name: Landing-Page
|
|
||||||
run: make landing-page
|
|
||||||
|
|
||||||
- name: Cppcheck-Report (XML)
|
- name: Cppcheck-Report (XML)
|
||||||
run: |
|
run: |
|
||||||
mkdir -p build
|
mkdir -p build
|
||||||
cppcheck --enable=all --inconclusive --xml --xml-version=2 \
|
cppcheck --enable=all --inconclusive --xml --xml-version=2 \
|
||||||
-I src src 2> build/cppcheck-report.xml || true
|
-I src src 2> build/cppcheck-report.xml || true
|
||||||
|
|
||||||
|
- name: Landing-Page
|
||||||
|
run: make landing-page
|
||||||
|
|
||||||
- name: Upload Coverage HTML
|
- name: Upload Coverage HTML
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
if: always()
|
if: always()
|
||||||
|
|||||||
@@ -139,12 +139,22 @@ def main() -> int:
|
|||||||
ncs = collect_docs("docs/non-conformities")
|
ncs = collect_docs("docs/non-conformities")
|
||||||
misra_r = collect_docs("misra/records")
|
misra_r = collect_docs("misra/records")
|
||||||
|
|
||||||
# Reports (existence-checked)
|
# Reports — Links zeigen auf BUNDLE-Pfade (relative zum index.html im Deploy).
|
||||||
rep_cov_idx = REPO / "build" / "coverage-html" / "index.html"
|
# Die CI-Pipeline deployt die Artefakte in genau diese Pfade,
|
||||||
rep_test_html = REPO / "build" / "test-report.html"
|
# darum ist deren Existenz hier irrelevant — Links werden immer emittiert.
|
||||||
rep_api = REPO / "build" / "api-doc" / "html" / "index.html"
|
rep_paths = {
|
||||||
rep_trace = REPO / "docs" / "traceability" / "index.html"
|
"coverage": "coverage/index.html",
|
||||||
rep_cppcheck = REPO / "build" / "cppcheck-report.xml"
|
"test": "reports/test-report.html",
|
||||||
|
"api": "api-doc/index.html",
|
||||||
|
"trace": "traceability/index.html",
|
||||||
|
"cppcheck": "reports/cppcheck-report.xml",
|
||||||
|
}
|
||||||
|
# Existence-Check zum Anzeigen "Generated?" — gegen den CI/lokalen Build-Pfad.
|
||||||
|
rep_cov_built = (REPO / "build" / "coverage-html" / "index.html").exists()
|
||||||
|
rep_test_built = (REPO / "build" / "test-report.html").exists()
|
||||||
|
rep_api_built = (REPO / "build" / "api-doc" / "html" / "index.html").exists()
|
||||||
|
rep_trace_built = (REPO / "docs" / "traceability" / "index.html").exists()
|
||||||
|
rep_cpp_built = (REPO / "build" / "cppcheck-report.xml").exists()
|
||||||
|
|
||||||
html_body = f"""<!doctype html>
|
html_body = f"""<!doctype html>
|
||||||
<html lang='de'><head>
|
<html lang='de'><head>
|
||||||
@@ -222,28 +232,18 @@ footer {{ text-align: center; color: #888; padding: 30px; font-size: 13px; }}
|
|||||||
|
|
||||||
html_body += "</div>"
|
html_body += "</div>"
|
||||||
|
|
||||||
# Reports
|
# Reports — Links immer setzen, Bundle-Pfade.
|
||||||
html_body += "<section><h2>Engineering-Reports (CI-generiert)</h2><ul>\n"
|
html_body += "<section><h2>Engineering-Reports (CI-generiert)</h2><ul>\n"
|
||||||
html_body += report_link("Traceability-Matrix",
|
html_body += report_link("Traceability-Matrix", rep_paths["trace"], True,
|
||||||
os.path.relpath(rep_trace, REPO),
|
|
||||||
rep_trace.exists(),
|
|
||||||
"SG -> SYS -> SA, SWE -> SWA -> Code+Test, bidirektional verifiziert")
|
"SG -> SYS -> SA, SWE -> SWA -> Code+Test, bidirektional verifiziert")
|
||||||
html_body += report_link("Test-Summary",
|
html_body += report_link("Test-Summary", rep_paths["test"], True,
|
||||||
os.path.relpath(rep_test_html, REPO),
|
|
||||||
rep_test_html.exists(),
|
|
||||||
f"{n_tests} Unit-Tests mit Anforderungs-Mapping")
|
f"{n_tests} Unit-Tests mit Anforderungs-Mapping")
|
||||||
html_body += report_link("Coverage (gcov/lcov)",
|
html_body += report_link("Coverage (gcov/lcov)", rep_paths["coverage"], True,
|
||||||
os.path.relpath(rep_cov_idx, REPO) if rep_cov_idx.exists() else "build/coverage-html/index.html",
|
|
||||||
rep_cov_idx.exists(),
|
|
||||||
"Statement + Branch Coverage, klickbar bis Zeilen-Level")
|
"Statement + Branch Coverage, klickbar bis Zeilen-Level")
|
||||||
html_body += report_link("API-Dokumentation (Doxygen)",
|
html_body += report_link("API-Dokumentation (Doxygen)", rep_paths["api"], True,
|
||||||
os.path.relpath(rep_api, REPO) if rep_api.exists() else "build/api-doc/html/index.html",
|
|
||||||
rep_api.exists(),
|
|
||||||
"Alle Header + Funktionen, mit @arch/@reqs/@asil")
|
"Alle Header + Funktionen, mit @arch/@reqs/@asil")
|
||||||
html_body += report_link("Cppcheck-Report (XML)",
|
html_body += report_link("Cppcheck-Report (XML)", rep_paths["cppcheck"], True,
|
||||||
os.path.relpath(rep_cppcheck, REPO) if rep_cppcheck.exists() else "build/cppcheck-report.xml",
|
"Statische Analyse + MISRA-Findings (XML zum Download)")
|
||||||
rep_cppcheck.exists(),
|
|
||||||
"Statische Analyse + MISRA-Findings")
|
|
||||||
html_body += "</ul></section>"
|
html_body += "</ul></section>"
|
||||||
|
|
||||||
# Diagrams
|
# Diagrams
|
||||||
|
|||||||
Reference in New Issue
Block a user