Nombrar la detección anterior y encadenar los tiempos de CaMa hasta el tratamiento
This commit is contained in:
@@ -140,7 +140,7 @@ describe('bars', () => {
|
||||
const t = bars(mode, () => r)!;
|
||||
expect(t.rows.map((x) => x.label)).toEqual([
|
||||
'Detección inicial',
|
||||
'Detección subsecuente',
|
||||
'Con detección anterior',
|
||||
'Sin dato',
|
||||
]);
|
||||
expect(t.rows.map((x) => x.cells)).toEqual([
|
||||
@@ -238,7 +238,7 @@ describe('bars', () => {
|
||||
c === 'initial'
|
||||
? 'Detección inicial'
|
||||
: c === 'subsequent'
|
||||
? 'Detección subsecuente'
|
||||
? 'Con detección anterior'
|
||||
: 'Sin dato',
|
||||
['initial', 'subsequent', 'no_data'],
|
||||
{ fill: true },
|
||||
@@ -251,14 +251,14 @@ describe('bars', () => {
|
||||
const y = (f.data[0] as any).y;
|
||||
expect(y).toEqual([
|
||||
'Detección inicial<br>Pacientes: 0',
|
||||
'Detección subsecuente<br>Pacientes: 8',
|
||||
'Con detección anterior<br>Pacientes: 8',
|
||||
'Sin dato<br>Pacientes: 2',
|
||||
]);
|
||||
expect((f.data[0] as any).x).toEqual([0, 75, 100]);
|
||||
});
|
||||
it('leaves out a group that does not reconcile', () => {
|
||||
const f = draw(reading({ 'subsequent|NILM': 6 }, 10));
|
||||
expect((f.data[0] as any).y).toEqual(['Detección subsecuente<br>Pacientes: 6']);
|
||||
expect((f.data[0] as any).y).toEqual(['Con detección anterior<br>Pacientes: 6']);
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -375,7 +375,7 @@ describe('independent bars by group', () => {
|
||||
)!;
|
||||
expect(g.groups.map((x) => [x.label, x.total])).toEqual([
|
||||
['Detección inicial', 4],
|
||||
['Detección subsecuente', 6],
|
||||
['Con detección anterior', 6],
|
||||
]);
|
||||
expect(g.groups[0].rows.map((r) => [r.label, r.text, r.percent, r.color])).toEqual([
|
||||
['Normal', '3/4 · 75.0 %', 75, '#408651'],
|
||||
@@ -530,7 +530,7 @@ describe('the subsequent round by last screening', () => {
|
||||
[25, 50, [50, 100]],
|
||||
]);
|
||||
});
|
||||
it('splits the subsequent round by last screening, keeping those without an answer', () => {
|
||||
it('splits the subsequent round by last screening, drawing only those with an answer', () => {
|
||||
const one = { 'initial-population': 1 };
|
||||
const r: Reading = {
|
||||
populations: { 'initial-population': 3 },
|
||||
@@ -554,7 +554,6 @@ describe('the subsequent round by last screening', () => {
|
||||
['within_1_year', 1],
|
||||
['2_years', 0],
|
||||
['3_or_more_years', 0],
|
||||
['subsequent_without_last_screening', 1],
|
||||
]);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user