feat(editorial): stage portfolio base data and territory for atomic publication

This commit is contained in:
2026-11-13 23:47:04 +02:00
parent d2c72f5e13
commit 2459d0ca37
11 changed files with 491 additions and 11 deletions
+32
View File
@@ -204,3 +204,35 @@ test('portfolio contributor cannot select publication of an approved edition', (
/value="publish"/,
);
});
test('portfolio review presents proposed base data and territory without applying them', () => {
const html = render({
subject: 'portfolio',
edition: {
...props.edition,
payload: {
...props.edition.payload,
resource: {
title: 'Ficha existente',
_structure: {
fields: {
name: 'Nome proposto',
budget_amount: '999999999999999999.99',
primary_territory_id: 'qa-district',
territory_version: 1,
},
territory_context: [
{ id: 'qa-district', name: 'Distrito sintético' },
],
},
},
files: [],
},
},
});
assert.match(html, /Alterações propostas nos dados-base/);
assert.match(html, /Nome proposto/);
assert.match(html, /999999999999999999.99/);
assert.match(html, /Localização proposta: Distrito sintético/);
assert.doesNotMatch(html, /qa-district|territory_version/);
});