package pt.fccn.mobile.arquivo.tests;

import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;

import java.io.IOException;

import org.junit.Test;

import pt.fccn.mobile.arquivo.pages.IndexPage;
import pt.fccn.saw.selenium.Retry;
import pt.fccn.saw.selenium.WebDriverTestBaseParalell;

public class FullTextSearchTest extends WebDriverTestBaseParalell {
		
	public FullTextSearchTest(String os, String version, String browser, String deviceName, String deviceOrientation) {
		super( os, version, browser, deviceName, deviceOrientation );
	}
	
	@Test
	//@Retry
	public void searchingTest( )  {
		System.out.print( "[Mobile] Running SearchTest Test. \n");
		IndexPage index = null;
		/**************************/
		/*** Portuguese version ***/ 
		/**************************/
        assertTrue("Failed The Search Test in Portuguese", index.checkSearch( "PT" ) );
        System.out.println( "Success The Search Test in Portuguese" );
        
        /***********************/
        /*** English version ***/ 
        /***********************/
        //assertTrue("Failed The Search Test in English", search.checkSearch( "EN" ) );
        //System.out.println( "Success The Search Test in English" );
 
		
    }
	
}

@@ -302,16 +302,67 @@
 aralell;
+%0Aimport pt.fccn.sobre.arquivo.pages.IndexSobrePage;
 %0A%0Apublic
@@ -749,16 +749,60 @@
 = null;%0A
+%09%09try%7B%0A%09%09%09index = new IndexPage( driver );%0A%09
 %09%09/*****
@@ -826,16 +826,17 @@
 ****/%0A%09%09
+%09
 /*** Por
@@ -859,16 +859,17 @@
 ***/ %0A%09%09
+%09
 /*******
@@ -881,32 +881,33 @@
 **************/%0A
+%09
         assertTr
@@ -974,24 +974,25 @@
 ( %22PT%22 ) );%0A
+%09
         Syst
@@ -1046,24 +1046,25 @@
 tuguese%22 );%0A
+%09
         %0A   
@@ -1060,16 +1060,17 @@
        %0A
+%09
         
@@ -1087,32 +1087,33 @@
 **************/%0A
+%09
         /*** Eng
@@ -1131,16 +1131,17 @@
 n ***/ %0A
+%09
         
@@ -1166,16 +1166,17 @@
 ******/%0A
+%09
         
@@ -1255,16 +1255,17 @@
 N%22 ) );%0A
+%09
         
@@ -1326,17 +1326,91 @@
 ish%22 );%0A
- 
+%09%09%7D catch( IOException e ) %7B%0A%09%09%09fail( %22IOException -%3E SearchingTest%22 );%0A%09%09%7D
 %0A%09%09%0A    

Initialize IndexPage