TASK-conversation-console-workflow: keep verification limits visible

This commit is contained in:
thePR0M3TH3AN committed 2026-10-01 08:08:21 -04:00
1 parent 8916038215
commit 6988fe3b1a
4 files changed
+36 -2

No files matched your search

+5
View File
@@ -2590,6 +2590,10 @@ test_integrity_note:
given: "The Console loads Overview and a reader selects each other supported view"
when: "The reader returns to Overview after visiting contextual views"
then: "Overview has the exact title TORCH Dashboard on initial and return navigation; all other views keep their exact contextual titles"
- id: SCN-console-owner-briefing-evidence-limitation-stays-visible
given: "The sample Console has a published owner briefing with reporting provenance"
when: "The owner briefing is rendered without opening compact provenance details"
then: "The warning that recorded evidence is not independent live verification remains visible, while exact publication time and reporting-window details stay in the collapsed disclosure"
- id: SCN-console-secondary-deeplink-focus-and-history
given: "The Console is loaded at the organization-proposals or approval-request-list fragment"
when: "The reader opens either direct link and uses browser Back and Forward"
@@ -2606,6 +2610,7 @@ test_integrity_note:
- "An unchanged current-revision preview, confirmation boundary, and draft retained after refresh"
- "A regenerated preview token and displayed revision bound to N+1"
- "Exact Overview and contextual view titles, plus focused in-viewport secondary targets across direct loads and browser history"
- "Visible recorded-evidence limitation beside owner briefing content while exact provenance remains compact and collapsed"
- "No browser requests to live project APIs and no changes to tracked screenshot expectations"
determinism_controls:
- "The existing isolated sample Console, fixed Playwright clock, and fixed desktop/mobile viewports"
+6 -1
View File
@@ -25,7 +25,12 @@ async function selectView(page, view) {
const link = page.locator(`.console-rail a[href="#${view}"]`);
assert.equal(await link.count(), 1, `the ${view} view must have one supported fragment link`);
if (await link.getAttribute('aria-current') !== 'page') await link.click();
await page.locator(`.console-workspace > [data-console-view="${view}"]`).waitFor({ state: 'visible' });
const viewSections = page.locator(`.console-workspace > [data-console-view="${view}"]`);
const visibleSections = page.locator(`.console-workspace > [data-console-view="${view}"]:not([hidden])`);
const sectionCount = await viewSections.count();
assert.ok(sectionCount > 0, `${view} must have a fragment-addressable workspace section`);
await visibleSections.first().waitFor({ state: 'visible' });
assert.equal(await visibleSections.count(), sectionCount, `all ${view} sections must be visible together`);
}
async function selectViewFor(page, selector) {
+10 -1
View File
@@ -182,7 +182,16 @@ function compactOwnerBriefingProvenance() {
timestamp.textContent = ageLabel(timestamp.getAttribute('datetime'));
timestamp.title = exactTime.textContent;
}
if (window) disclosure.append(window);
if (window) {
const limitation = 'Recorded evidence, not independent live verification.';
if (window.textContent.includes(limitation)) {
const visibleLimitation = window.cloneNode(false);
visibleLimitation.textContent = limitation;
window.textContent = window.textContent.replace(limitation, '').trim();
window.after(visibleLimitation);
}
disclosure.append(window);
}
publication.append(disclosure);
}
@@ -60,6 +60,21 @@ test('SCN-console-view-title-mapping: Overview retains its dashboard title while
await assertSelectedView(page, 'overview', 'Overview');
});
test('SCN-console-owner-briefing-evidence-limitation-stays-visible: collapsed provenance keeps the warning visible', async (t) => {
const { page } = await openDemo(t, { width: 1280, height: 900 });
await page.locator('.console-rail a[href="#owner-briefing"]').click();
const publication = page.locator('#owner-briefing-content .briefing-publication');
const warning = publication.locator(':scope > p.briefing-muted').filter({ hasText: 'Recorded evidence, not independent live verification.' });
const provenance = publication.locator('details.briefing-provenance').filter({ hasText: 'Publication time and reporting window' });
assert.equal(await warning.count(), 1);
assert.equal(await warning.isVisible(), true);
assert.match(await page.locator('#owner-briefing').innerText(), /not independent live verification/);
assert.equal(await provenance.count(), 1);
assert.equal(await provenance.evaluate((details) => details.open), false);
assert.equal(await provenance.locator('time').count(), 1, 'the exact publication time remains in compact metadata');
assert.equal(await provenance.locator('time').isVisible(), false, 'publication time stays inside the closed disclosure');
});
test('SCN-console-secondary-deeplink-focus-and-history: direct fragments and history land on the actual target', async (t) => {
const { page } = await openDemo(t, { width: 390, height: 844 });
const base = `http://127.0.0.1:${new URL(page.url()).port}/console?demo=1`;