source: devel/testlink/automation/src/test/java/br/gov/serpro/cte/email/compor/EnviarEmailTestCase.java @ 3521

Revision 3521, 1.5 KB checked in by luiz-fernando, 13 years ago (diff)

Ticket #1402 - Automacao dos casos de teste do Expresso documentados no Testlink

Line 
1package br.gov.serpro.cte.email.compor;
2
3import org.junit.Test;
4
5import br.gov.serpro.cte.common.ExpressoMailTestCase;
6
7/**
8 * TODO Ainda nao consegui pegar o campo do RichTextEditor para colocar conteudo
9 * ao corpo do email.
10 *
11 * @author L.F.Estivalet (Serpro)
12 *
13 *         Created on Nov 16, 2010 at 4:00:58 PM
14 *
15 */
16public class EnviarEmailTestCase extends ExpressoMailTestCase {
17
18        @Test
19        public void testaEnviarEmail() throws Exception {
20                super.composeEmail(Valor.EMAIL_TESTE_1.getValue(),
21                                Valor.ASSUNTO.getValue());
22                super.sendEmail();
23        }
24
25        @Test
26        public void testaEnviarEmailSemDestinatario() throws Exception {
27                super.composeEmail("", Valor.ASSUNTO_SEM_DESTINATARIO.getValue());
28                super.sendEmail();
29                super.assertMessage(Mensagem.SEM_DESTINATARIO.getValue());
30        }
31
32        @Test
33        public void testaEnviarEmailDestinatarioInvalido() throws Exception {
34                super.composeEmail(Valor.EMAIL_INVALIDO.getValue(),
35                                Valor.ASSUNTO_EMAIL_INVALIDO.getValue());
36                super.sendEmail();
37                super.assertMessage(Mensagem.DESTINATARIO_INVALIDO.getValue());
38        }
39
40        @Test
41        public void testaEnviarEmailSemAssunto() throws Exception {
42                super.composeEmail(Valor.EMAIL_TESTE_1.getValue(), "");
43                super.sendEmail();
44                assertTrue(selenium.getConfirmation().matches(
45                                Mensagem.SEM_ASSUNTO.getValue()));
46        }
47
48        @Test
49        public void testaEnviarEmailMultiplosDestinatarios() throws Exception {
50                super.composeEmail(Valor.EMAIL_TESTE_MULTIPLOS.getValue(),
51                                Valor.ASSUNTO_MULTIPLOS_DESTINATARIOS.getValue());
52                super.sendEmail();
53        }
54
55}
Note: See TracBrowser for help on using the repository browser.