Subversion Repositories eFlore/Applications.del

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
1013 aurelien 1
package org.tela_botanica.del.test.modeles;
2
 
3
import static org.junit.Assert.*;
4
 
5
import org.junit.Before;
6
import org.junit.Test;
7
import org.tela_botanica.del.client.modeles.Image;
8
import org.tela_botanica.del.client.modeles.Observation;
9
 
10
public class ImageTest {
11
 
12
	Image testImage;
13
	Observation testObservation;
14
 
15
	@Before
16
    public void setUp() {
17
		testImage = new Image();
18
		testObservation = new Observation();
19
		testImage.setObservation(testObservation);
20
	}
21
 
22
	@Test
23
	public void testEstADeterminerCarNomRetenuVide() {
24
		testObservation.setNomRetenu("");
25
		assertEquals(testImage.estADeterminer(), true);
26
	}
27
 
28
	@Test
29
	public void testEstADeterminerCarTagImageADeterminer() {
30
		testImage.ajouterMotsClef("aDeterminer");
31
		assertEquals(testImage.estADeterminer(), true);
32
	}
33
 
34
	@Test
35
	public void testEstADeterminerTagObservationADeterminer() {
36
		testObservation.ajouterMotsClef("aDeterminer");
37
		assertEquals(testImage.estADeterminer(), true);
38
	}
39
 
40
}