Subversion Repositories eFlore/Applications.del

Rev

Rev 380 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 380 Rev 413
Line 2... Line 2...
2
 
2
 
Line 3... Line 3...
3
import static org.junit.Assert.*;
3
import static org.junit.Assert.*;
4
 
4
 
5
import org.junit.Before;
-
 
6
import org.junit.Test;
5
import org.junit.Before;
7
import org.tela_botanica.del.client.vues.rechercheimages.MoteurRechercheImagePresenteur.Vue;
6
import org.junit.Test;
Line -... Line 7...
-
 
7
import org.tela_botanica.del.client.services.rest.ImageService;
-
 
8
import org.tela_botanica.del.client.vues.rechercheimages.resultats.ResultatRechercheImagePresenteur;
8
import org.tela_botanica.del.client.services.rest.ImageServiceConcret;
9
 
Line 9... Line 10...
9
import org.tela_botanica.del.client.vues.rechercheimages.resultats.ResultatRechercheImagePresenteur;
10
import com.google.gwt.user.client.ui.HasWidgets;
Line 10... Line 11...
10
 
11
 
11
import static org.mockito.Mockito.mock;
12
import static org.mockito.Mockito.*;
12
 
13
 
-
 
14
public class ResultatRechercheImagePresenteurTest {
Line 13... Line 15...
13
public class ResultatRechercheImagePresenteurTest {
15
 
14
 
16
	private ResultatRechercheImagePresenteur resultatPresenteur;
Line 15... Line 17...
15
	private ResultatRechercheImagePresenteur resultatPresenteur;
17
	private org.tela_botanica.del.client.vues.rechercheimages.MoteurRechercheImagePresenteur.Vue vueMoteurRecherche;
-
 
18
	private org.tela_botanica.del.client.vues.rechercheimages.resultats.ResultatRechercheImagePresenteur.Vue vueResultat;
16
	private Vue vueMoteurRecherche;
19
	private ImageService serviceImage;
-
 
20
	
17
	private org.tela_botanica.del.client.vues.rechercheimages.resultats.ResultatRechercheImagePresenteur.Vue vueResultat;
21
	@Before
-
 
22
	public void setUp() throws Exception {
18
	
23
		
Line 19... Line 24...
19
	@Before
24
		vueResultat = mock(org.tela_botanica.del.client.vues.rechercheimages.resultats.ResultatRechercheImagePresenteur.Vue.class);
Line 20... Line 25...
20
	public void setUp() throws Exception {
25
		serviceImage = mock(ImageService.class); 
21
		
26
		resultatPresenteur = new ResultatRechercheImagePresenteur(serviceImage, vueResultat);
-
 
27
		vueMoteurRecherche = mock(org.tela_botanica.del.client.vues.rechercheimages.MoteurRechercheImagePresenteur.Vue.class);
-
 
28
		HasWidgets zoneResultats = mock(HasWidgets.class);
22
		vueResultat = mock(org.tela_botanica.del.client.vues.rechercheimages.resultats.ResultatRechercheImagePresenteur.Vue.class);
29
		when(vueMoteurRecherche.getZoneResultats()).thenReturn(zoneResultats);
23
		resultatPresenteur = new ResultatRechercheImagePresenteur(new ImageServiceConcret(), vueResultat);
30
		resultatPresenteur.go(vueMoteurRecherche.getZoneResultats());
Line 24... Line 31...
24
		vueMoteurRecherche = mock(Vue.class);
31