Preservar a oportunidade durante o registo e preparacao do perfil
This commit is contained in:
@@ -135,3 +135,31 @@ test('candidate profile renders geography and retained version without internal
|
||||
expect(html).not.toContain('Aprovar');
|
||||
expect(html).not.toContain('/pessoas');
|
||||
});
|
||||
|
||||
test('a newly registered candidate can resume the selected opportunity after preparing the profile without automatic submission', () => {
|
||||
const initialPage = {
|
||||
...page,
|
||||
component: 'candidate/profile',
|
||||
props: {
|
||||
...page.props,
|
||||
companyId: 1,
|
||||
email: 'new@example.invalid',
|
||||
selectedOpportunity: { id: 7, title: 'Serviço escolhido' },
|
||||
profile: {
|
||||
version: 0,
|
||||
data: {
|
||||
name: '',
|
||||
phone: '',
|
||||
summary: '',
|
||||
availability: { province: '', district: '', locality: '' },
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
const html = renderToString(
|
||||
<App initialPage={initialPage} initialComponent={Profile} />,
|
||||
);
|
||||
expect(html).toContain('Serviço escolhido');
|
||||
expect(html).toContain('/candidaturas/1/oportunidades/7');
|
||||
expect(html).toContain('A candidatura só será enviada quando confirmar');
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user