Merge parity/F1a

This commit is contained in:
2026-12-01 11:52:00 -06:00
15 changed files with 197 additions and 155 deletions
+30 -1
View File
@@ -132,10 +132,16 @@ test('tea gobernanza: every section in sync mode, and the preview saved as PDF',
'Ejecución',
'Modelos',
'Entrenamiento',
'Subir archivos',
'Bundles',
'Estudios EEG',
'Vista previa',
]);
await expect(page.locator('app-eeg-preview')).toHaveCount(0);
await expect(page.getByText('Archivos de entrenamiento', { exact: true })).toHaveCount(0);
const uploads = page.getByRole('region', { name: 'Subir archivos' });
await expect(uploads.getByLabel('Conjunto')).toBeVisible();
await expect(uploads.getByRole('button', { name: 'Archivos', exact: true })).toBeVisible();
await expect(uploads.getByRole('button', { name: 'Subir archivos' })).toBeDisabled();
await page.getByRole('combobox', { name: 'Modo' }).click();
await page.getByRole('option', { name: 'Sync' }).click();
await expect(page.getByRole('status').filter({ hasText: 'Disponible' })).toBeVisible();
@@ -146,6 +152,21 @@ test('tea gobernanza: every section in sync mode, and the preview saved as PDF',
await expect(training).toBeFocused();
await expect(page.locator('app-governance-training formly-form')).toBeVisible();
const source = page.getByRole('combobox', { name: 'Origen' });
const folder = page.getByLabel('Carpeta', { exact: true });
const line = page.getByRole('combobox', { name: 'Frecuencia de la red eléctrica (Hz)' });
await expect(source).toHaveText('Niños del sitio sin el diagnóstico');
await expect(folder).toBeHidden();
await expect(line).toBeHidden();
await source.click();
await page.getByRole('option', { name: 'Carpeta de EDF con edades' }).click();
await expect(folder).toBeVisible();
await expect(line).toBeVisible();
await source.click();
await page.getByRole('option', { name: 'Niños del sitio sin el diagnóstico' }).click();
await expect(folder).toBeHidden();
await expect(line).toBeHidden();
const monitor = page.locator('app-governance-models app-run-monitor');
await page.getByRole('button', { name: 'Analizar EEG' }).click();
await expect(page.getByRole('heading', { name: 'Análisis de EEG' })).toBeVisible();
@@ -157,6 +178,7 @@ test('tea gobernanza: every section in sync mode, and the preview saved as PDF',
await expect(page.getByText('No hay candidatas que se puedan promover.')).toBeVisible();
const studies = page.locator('app-eeg-studies');
await expect(studies.locator('input[type=file]')).toHaveCount(0);
await expect(studies.locator('table.eegs tbody tr').first()).toContainText(/Válido|No válido/);
await studies.locator('table.eegs tbody button:enabled').first().click();
await expect(studies.getByRole('heading', { name: /^EEG .* meses$/ })).toBeVisible();
@@ -166,7 +188,14 @@ test('tea gobernanza: every section in sync mode, and the preview saved as PDF',
{ timeout: 10 * 60_000 },
);
await page
.locator('app-governance-models')
.getByRole('button', {
name: 'Evaluar un solo estudio',
})
.click();
const preview = page.locator('app-eeg-preview');
await expect(preview.getByRole('heading', { name: 'Vista previa' })).toBeVisible();
await preview.getByLabel('EDF').setInputFiles(process.env['TEA_EDF']!);
await preview.getByLabel('ADOS-2 (PDF)').setInputFiles(process.env['TEA_ADOS2']!);
await preview.getByLabel('Fecha de nacimiento').fill(process.env['TEA_BIRTH']!);