fix(web): clarify act context and operational map
DH V2 CI / API · typecheck, tests, build (push) Successful in 36s
Production dependency audit / API · production dependencies (push) Successful in 8s
Production dependency audit / WEB · production dependencies (push) Successful in 9s
DH V2 CI / WEB · typecheck, build (push) Successful in 1m37s
DH V2 CI / Docker / migrations / production images (push) Successful in 1m52s
DH V2 CI / Promote verified main to deploy (push) Successful in 4s
Android CI / RC / Android · lint, tests, debug APK, release compile (push) Successful in 4m11s
DH V2 CI / API · typecheck, tests, build (push) Successful in 36s
Production dependency audit / API · production dependencies (push) Successful in 8s
Production dependency audit / WEB · production dependencies (push) Successful in 9s
DH V2 CI / WEB · typecheck, build (push) Successful in 1m37s
DH V2 CI / Docker / migrations / production images (push) Successful in 1m52s
DH V2 CI / Promote verified main to deploy (push) Successful in 4s
Android CI / RC / Android · lint, tests, debug APK, release compile (push) Successful in 4m11s
This commit is contained in:
@@ -4,9 +4,9 @@ import { readFileSync } from 'node:fs';
|
||||
import { resolve } from 'node:path';
|
||||
import { API_PHASE, API_VERSION } from '../../src/version';
|
||||
|
||||
test('health metadata reports the current F6.14 release', () => {
|
||||
assert.equal(API_PHASE, 'F6.14');
|
||||
test('health metadata reports the current F6.15 release', () => {
|
||||
assert.equal(API_PHASE, 'F6.15');
|
||||
const pkg = JSON.parse(readFileSync(resolve(process.cwd(), 'package.json'), 'utf8')) as { version: string };
|
||||
assert.equal(API_VERSION, pkg.version);
|
||||
assert.equal(API_VERSION, '0.29.0-14');
|
||||
assert.equal(API_VERSION, '0.29.0-15');
|
||||
});
|
||||
|
||||
@@ -13,7 +13,7 @@ test('F6.1 presentation metadata keeps the visible WEB version aligned with pack
|
||||
const visibleVersion = version.match(/APP_VERSION\s*=\s*'([^']+)'/)?.[1];
|
||||
|
||||
assert.equal(visibleVersion, pkg.version);
|
||||
assert.match(version, /APP_PHASE\s*=\s*'F6\.13/);
|
||||
assert.match(version, /APP_PHASE\s*=\s*'F6\.15/);
|
||||
});
|
||||
|
||||
test('F6.1 presentation keeps Relevamientos retired from WEB navigation and routes', () => {
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
import assert from 'node:assert/strict';
|
||||
import { readFileSync } from 'node:fs';
|
||||
import { resolve } from 'node:path';
|
||||
import test from 'node:test';
|
||||
|
||||
function api(path: string) { return readFileSync(resolve(process.cwd(), path), 'utf8'); }
|
||||
function web(path: string) { return readFileSync(resolve(process.cwd(), `../web-v2/src/${path}`), 'utf8'); }
|
||||
|
||||
test('F6.15 Acta exposes full territorial and affected-inventory context', () => {
|
||||
const acts = api('src/inspection-acts/inspection-acts.service.ts');
|
||||
const findings = api('src/inspection-findings/inspection-findings.service.ts');
|
||||
const page = web('pages/InspectionActEditorPage.tsx');
|
||||
const media = web('features/inspections/InspectionActMediaPanel.tsx');
|
||||
for (const field of ['department', 'area', 'yacimiento', 'company', 'installations', 'subinstallations']) {
|
||||
assert.match(acts, new RegExp(`'${field}'`));
|
||||
}
|
||||
assert.match(acts, /legacyAreaScope/);
|
||||
assert.match(findings, /'hierarchy'/);
|
||||
assert.match(findings, /'installation'/);
|
||||
assert.match(findings, /'subinstallation'/);
|
||||
assert.match(page, /Ubicación territorial y operativa/);
|
||||
assert.match(page, /No definido en la Inspección histórica/);
|
||||
assert.match(media, /Elemento afectado:/);
|
||||
assert.match(media, /Constatación:/);
|
||||
});
|
||||
|
||||
test('F6.15 Acta uses real report workflow state instead of legacy generated PDF status', () => {
|
||||
const acts = api('src/inspection-acts/inspection-acts.service.ts');
|
||||
const page = web('pages/InspectionActEditorPage.tsx');
|
||||
const list = web('pages/ActsPage.tsx');
|
||||
assert.match(acts, /'gedoIfIdentifier'/);
|
||||
assert.match(acts, /'gedoOfficializedAt'/);
|
||||
assert.match(acts, /'wordStatus'/);
|
||||
assert.match(page, /act\.report\.status === 'OFFICIALIZED'/);
|
||||
assert.match(page, /Oficializado en GEDO/);
|
||||
assert.doesNotMatch(page, /act\.report\.pdfStatus === 'READY'/);
|
||||
assert.match(list, /act\.report\.status === 'OFFICIALIZED'/);
|
||||
});
|
||||
|
||||
test('F6.15 map exposes filtered operational layers without inventing coordinates', () => {
|
||||
const controller = api('src/asset-master/asset-geometries.controller.ts');
|
||||
const service = api('src/asset-master/asset-geometries.service.ts');
|
||||
const page = web('pages/MapPage.tsx');
|
||||
const map = web('features/map/DhMap.tsx');
|
||||
assert.match(controller, /@Controller\('map\/context'\)/);
|
||||
assert.match(controller, /@Controller\('map\/documents'\)/);
|
||||
assert.match(service, /WITH RECURSIVE y_tree/);
|
||||
assert.match(service, /ST_Centroid\(ST_Collect\(geometry\.geometry\)\)/);
|
||||
assert.match(service, /COALESCE\(finding\.target_geometry,finding\.fallback_geometry\)/);
|
||||
for (const kind of ['YACIMIENTO', 'COMPANY', 'ACT', 'FINDING']) {
|
||||
assert.match(service, new RegExp(`'${kind}'::text`));
|
||||
assert.match(page, new RegExp(`${kind}:`));
|
||||
}
|
||||
assert.match(page, /Buscar Yacimiento, Empresa, Acta, Hallazgo/);
|
||||
assert.match(page, /sourceGeometries/);
|
||||
assert.match(map, /yacimiento-points/);
|
||||
assert.match(map, /company-points/);
|
||||
assert.match(map, /act-points/);
|
||||
assert.match(map, /finding-points/);
|
||||
});
|
||||
Reference in New Issue
Block a user