-
Notifications
You must be signed in to change notification settings - Fork 0
/
testClasseTache.java
60 lines (45 loc) · 1.27 KB
/
testClasseTache.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
package gestionnairedetache;
import static org.junit.Assert.*;
import java.util.Arrays;
import java.util.Collection;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
import org.junit.runners.Parameterized.Parameter;
import org.junit.runners.Parameterized.Parameters;
@RunWith(Parameterized.class)
public class testClasseTache {
@Parameter (value = 0)
public int idTache;
@Parameter (value = 1)
public String nomTache;
@Parameter (value = 2)
public String descriptionTache;
@Parameter (value = 3)
public String statusTache;
@Parameters
public static Collection<Object[]> data(){
Object[][] data = new Object[][] {{1, "tache", "Description1", "nouveau"}, {2, "Tache2", "Description2", "terminer"}};
return Arrays.asList(data);
}
@Test
public void testSetIdTache() {
Tache tache = new Tache();
assertEquals(idTache, tache.getId());
}
@Test
public void testSetNomTache() {
Tache tache = new Tache();
assertEquals(nomTache, tache.getNom());
}
@Test
public void testSetDescriptionTache() {
Tache tache = new Tache();
assertEquals(descriptionTache, tache.getDescription());
}
@Test
public void testSetStatusTache() {
Tache tache = new Tache();
assertEquals(statusTache, tache.getStatus());
}
}