diff --git a/demo/scenario.py b/demo/scenario.py
index 3419afc..bfe1869 100644
--- a/demo/scenario.py
+++ b/demo/scenario.py
@@ -190,7 +190,7 @@ class DemoIssue:
summary="Search products by SKU",
status="Ready for release",
category="done",
- links=(f"{ENDPOINT}/shop/web/-/merge_requests/99",),
+ links=(f"{ENDPOINT}/shop/web/-/merge_requests/99", f"{ENDPOINT}/shop/api/-/merge_requests/54"),
),
DemoIssue(
key="SHOP-35",
diff --git a/docs/page.md b/docs/page.md
index c08ab81..d64b8a0 100644
--- a/docs/page.md
+++ b/docs/page.md
@@ -39,8 +39,8 @@ Opening a line shows:
- a link to create the next tag on the head, when rows have no tag yet;
- the rows, each with its tags and their pipelines, its merge requests or commits with when they were merged or
committed, Jira keys with their status, the time each environment first ran it, and failed jobs. Rows out of scope
- are dimmed. Each Jira key says why the row carries it: `named` when the merge request or commit mentions it,
- `linked` when the Jira issue links to the change, or both.
+ are dimmed. A key the merge request or commit does not mention, which the row carries only because the Jira
+ issue links to the change, is underlined with a dashed line and marked `via Jira`; hover over it for the reason.
Links open in a new tab, including the GitLab settings pages that warnings and errors point to.
diff --git a/release_scope/_static/index.html b/release_scope/_static/index.html
index 86b2e71..44c1f4c 100644
--- a/release_scope/_static/index.html
+++ b/release_scope/_static/index.html
@@ -127,6 +127,8 @@
.issue-row.chosen { background: color-mix(in srgb, var(--accent) 10%, transparent); }
.issue-row code { font-weight: 500; }
.gaps ul { margin: 4px 0 12px; padding-left: 18px; }
+ .row-key.via-jira > a { text-decoration: underline dashed; text-underline-offset: 3px; }
+ .link-icon { width: 13px; height: 13px; margin-right: 2px; vertical-align: -2px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.issue-row .summary { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.issue-row .reach { grid-column: 3 / -1; display: flex; gap: 4px; overflow: hidden; white-space: nowrap; }
.rider-mark { padding: 0 6px; border: 1px dashed var(--warn); border-radius: 999px; color: var(--warn); font-size: 11px; white-space: nowrap; }
@@ -285,9 +287,10 @@
-
+
@@ -561,9 +564,8 @@
planNoTag: "{keys}: no tag yet.",
planElsewhere: "{items}, nothing to pick",
groupRelated: "Related",
- viaNamed: "named",
- viaLinked: "linked",
- viaTitle: "named: the merge request or commit mentions the key; linked: the Jira issue links to this change",
+ viaJira: "via Jira",
+ viaJiraTitle: "Not mentioned in {change}. {key} links to it in Jira.",
taskFrom: "from {items}",
gapsTitle: "Left behind by these picks:",
gapNeeds: "needs {tag}",
@@ -670,9 +672,8 @@
planNoTag: "{keys}: тега ещё нет.",
planElsewhere: "{items}, выбирать нечего",
groupRelated: "Связанные",
- viaNamed: "в тексте",
- viaLinked: "по ссылке",
- viaTitle: "в тексте: ключ упомянут в MR или коммите; по ссылке: задача в Jira ссылается на это изменение",
+ viaJira: "через Jira",
+ viaJiraTitle: "{change} не упоминает задачу. {key} ссылается на это изменение в Jira.",
taskFrom: "из {items}",
gapsTitle: "Не войдёт с этими тегами:",
gapNeeds: "нужен {tag}",
@@ -954,8 +955,8 @@
changeLabel(row) {
return row.merge_requests.length ? row.merge_requests.map((item) => "!" + item.iid).join(" ") : row.commits[0].short_sha;
},
- viaText(key) {
- return key.via.map((source) => this.t(source === "named" ? "viaNamed" : "viaLinked")).join(", ");
+ viaJira(key) {
+ return !key.via.includes("named");
},
relationLabel(relation) {
if (relation.kind === "parent") return this.t("relationParent");
diff --git a/tests/test_browser.py b/tests/test_browser.py
index 78c8fec..e76d0a3 100644
--- a/tests/test_browser.py
+++ b/tests/test_browser.py
@@ -313,16 +313,20 @@ def test_demo_service_rows_line_up_with_and_without_a_pick(page: Page, demo_site
assert errors == []
-def test_row_keys_say_whether_the_change_names_them_or_jira_links_them(
- page: Page, site: str, errors: list[str]
+def test_demo_only_a_key_the_change_does_not_mention_is_marked_as_via_jira(
+ page: Page, demo_site: str, errors: list[str]
) -> None:
- page.goto(site)
+ page.goto(demo_site)
- page.locator("details.service summary").click()
+ api: typing.Final = _demo_service(page, "shop/api")
+ api.locator("summary").click()
- row_key: typing.Final = page.locator(".row-key", has=page.locator("a", has_text="SHOP-12")).first
- expect(row_key.locator(".via")).to_have_text("named, linked")
- expect(page.locator(".row-key", has=page.locator("a", has_text="SHOP-9")).locator(".via")).to_have_text("named")
+ linked: typing.Final = api.locator(".row-key.via-jira")
+ expect(linked).to_have_count(1)
+ expect(linked.locator("a")).to_have_text("SHOP-33")
+ expect(linked.locator(".via")).to_have_text("via Jira")
+ expect(linked).to_have_attribute("title", "Not mentioned in !54. SHOP-33 links to it in Jira.")
+ expect(api.locator(".row-key", has=page.locator("a", has_text="SHOP-38")).locator(".via")).to_be_hidden()
assert errors == []
|