You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add web-link field to Result for browsable test links (#4878)
## Summary
Add a `web_link` field to the `Result` dataclass in `tmt/result.py` that
serializes
the browsable test source URL directly into `results.yaml` as
`web-link`, so downstream
consumers (gluetools, kcidb) get a ready-to-use link instead of having
to reconstruct it
from `fmf-id`.
- The field name is consistent with the existing `Core.web_link()`
method and `tmt test show` output
- Populated via `Test.web_link()` in `from_test_invocation()`
- Returns `None` for local tests / shell discover (no URL available)
- Returns a browsable URL for tests from Git repos (GitLab, GitHub,
Pagure, etc.)
### Example output in results.yaml
```yaml
- name: /tests/nvidia/driver-install
result: pass
fmf-id:
url: https://gitlab.cee.redhat.com/gpu-accelerators/tests
ref: main
name: /tests/nvidia/driver-install
path: .
web-link: https://gitlab.cee.redhat.com/gpu-accelerators/tests/-/blob/main/tests/nvidia/driver-install/main.fmf
duration: 00:05:23
serial-number: 1
```
Ref: TFT-2683
---------
Signed-off-by: Israel Santana Aleman <isantana@redhat.com>
Co-authored-by: Israel Santana Aleman <isantana@redhat.com>
0 commit comments