incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From liu...@apache.org
Subject svn commit: r1378870 [6/6] - in /incubator/ooo/trunk/main/test: ./ inc/ prj/ source/ testcommon/ testcommon/source/org/openoffice/test/common/ testgui/source/testcase/gui/ testgui/source/testcase/gui/bvt/ testgui/source/testcase/gui/formula/catalog/ te...
Date Thu, 30 Aug 2012 09:27:23 GMT
Modified: incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sc/OperationOnSampleFile.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sc/OperationOnSampleFile.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sc/OperationOnSampleFile.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sc/OperationOnSampleFile.java Thu Aug 30 09:27:21 2012
@@ -23,20 +23,11 @@
  * 
  */
 
-
-
 package testcase.gui.svt.sc;
 
-import static org.openoffice.test.common.Testspace.prepareData;
-import static testlib.gui.AppUtil.typeKeys;
-import static org.openoffice.test.vcl.Tester.sleep;
-import static org.openoffice.test.vcl.Tester.typeKeys;
-import static testlib.gui.AppUtil.submitOpenDlg;
-import static testlib.gui.UIMap.SCAfterCurrentSheet;
-import static testlib.gui.UIMap.SCInsertSheetDlg;
-import static testlib.gui.UIMap.SCNewSheetName;
-import static testlib.gui.UIMap.app;
-import static testlib.gui.UIMap.writer;
+import static org.openoffice.test.common.Testspace.*;
+import static org.openoffice.test.vcl.Tester.*;
+import static testlib.gui.AppUtil.*;
 import static testlib.gui.UIMap.*;
 
 import java.io.FileOutputStream;
@@ -48,20 +39,20 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 import org.openoffice.test.OpenOffice;
+import org.openoffice.test.common.Logger;
 import org.openoffice.test.common.SystemUtil;
 import org.openoffice.test.common.Testspace;
 
 import testlib.gui.CalcUtil;
-import testlib.gui.Log;
 
 public class OperationOnSampleFile {
 	@Rule
-	public Log LOG = new Log();
-	
+	public Logger log = Logger.getLogger(this);
+
 	private PrintStream result = null;
-	
+
 	private String pid = null;
-	
+
 	/**
 	 * @throws java.lang.Exception
 	 */
@@ -71,9 +62,9 @@ public class OperationOnSampleFile {
 		app.start();
 		result = new PrintStream(new FileOutputStream(Testspace.getFile("output/svt_sc_sample1.csv")));
 		HashMap<String, Object> proccessInfo = SystemUtil.findProcess(".*(soffice\\.bin|soffice.*-env).*");
-		pid = (String)proccessInfo.get("pid");
+		pid = (String) proccessInfo.get("pid");
 		result.println("Iterator,Time,Memory(KB),CPU(%)");
-		LOG.info("Result will be saved to " + Testspace.getPath("output/svt_sc_sample1.csv"));
+		log.info("Result will be saved to " + Testspace.getPath("output/svt_sc_sample1.csv"));
 	}
 
 	@After
@@ -81,21 +72,19 @@ public class OperationOnSampleFile {
 		app.close();
 		result.close();
 	}
-	
+
 	@Test
 	public void operationOnSampleFile() throws Exception {
 		String file = prepareData("svt/complex.ods");
 		String pic = prepareData("svt/Sunset.jpg");
-		String [][] inputStr = { { "Area", "Item", "Count" }, { "1", "2", "3" },
-				{ "4", "5", "6" }, { "7", "8", "9" }, { "10", "11", "12" }};	
-		for(int i = 0; i < 1000; i++)
-		{
+		String[][] inputStr = { { "Area", "Item", "Count" }, { "1", "2", "3" }, { "4", "5", "6" }, { "7", "8", "9" }, { "10", "11", "12" } };
+		for (int i = 0; i < 1000; i++) {
 			app.dispatch(".uno:Open");
 			submitOpenDlg(file);
 			calc.waitForExistence(20, 2);
 			sleep(2);
-			
-			//Insert Chart
+
+			// Insert Chart
 			app.dispatch(".uno:Insert");
 			SCAfterCurrentSheet.check();
 			SCNewSheetName.setText("Instant Chart");
@@ -114,8 +103,8 @@ public class OperationOnSampleFile {
 			sleep(5);
 			calc.typeKeys("<esc>");
 			sleep(5);
-			
-			//Insert Graphic and Fontwork
+
+			// Insert Graphic and Fontwork
 			app.dispatch(".uno:Insert");
 			SCAfterCurrentSheet.check();
 			SCNewSheetName.setText("Instant Graphic and fontwork");
@@ -138,26 +127,25 @@ public class OperationOnSampleFile {
 			sleep(2);
 			calc.typeKeys("<esc>");
 			sleep(2);
-			
+
 			// Close file
 			calc.menuItem("File->Close").select();
 			ActiveMsgBox.no();
 			sleep(2);
-			
+
 			HashMap<String, Object> perfData = SystemUtil.getProcessPerfData(pid);
 			String record = i + "," + System.currentTimeMillis() + "," + perfData.get("rss") + "," + perfData.get("pcpu");
-			LOG.info("Record: " + record);
+			log.info("Record: " + record);
 			result.println(record);
 			result.flush();
-			
+
 			sleep(3);
-			
+
 		}
-		
-		
+
 	}
-	public static void inputCells(String [][]inputs)
-	{
+
+	public static void inputCells(String[][] inputs) {
 		String back = "";
 		for (int i = 0; i < inputs.length; i++) {
 			calc.typeKeys(back);

Modified: incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sd/OperationOnNewSD.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sd/OperationOnNewSD.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sd/OperationOnNewSD.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sd/OperationOnNewSD.java Thu Aug 30 09:27:21 2012
@@ -25,10 +25,9 @@
 
 package testcase.gui.svt.sd;
 
-import static testlib.gui.AppUtil.submitSaveDlg;
-import static testlib.gui.UIMap.PresentationWizard;
-import static testlib.gui.UIMap.app;
-import static testlib.gui.UIMap.startcenter;
+import static org.openoffice.test.common.Testspace.*;
+import static org.openoffice.test.vcl.Tester.*;
+import static testlib.gui.AppUtil.*;
 import static testlib.gui.UIMap.*;
 
 import java.io.FileOutputStream;
@@ -41,22 +40,18 @@ import org.junit.Rule;
 import org.junit.Test;
 import org.openoffice.test.OpenOffice;
 import org.openoffice.test.common.FileUtil;
+import org.openoffice.test.common.Logger;
 import org.openoffice.test.common.SystemUtil;
 import org.openoffice.test.common.Testspace;
 
-import static org.openoffice.test.common.Testspace.prepareData;
-import static org.openoffice.test.vcl.Tester.*;
-
-import testlib.gui.Log;
-
 public class OperationOnNewSD {
 	@Rule
-	public Log LOG = new Log();
-	
+	public Logger log = Logger.getLogger(this);
+
 	private PrintStream result = null;
-	
+
 	private String pid = null;
-	
+
 	/**
 	 * @throws java.lang.Exception
 	 */
@@ -66,9 +61,9 @@ public class OperationOnNewSD {
 		app.start();
 		result = new PrintStream(new FileOutputStream(Testspace.getFile("output/svt_sd_new.csv")));
 		HashMap<String, Object> proccessInfo = SystemUtil.findProcess(".*(soffice\\.bin|soffice.*-env).*");
-		pid = (String)proccessInfo.get("pid");
+		pid = (String) proccessInfo.get("pid");
 		result.println("Iterator,Time,Memory(KB),CPU(%)");
-		LOG.info("Result will be saved to " + Testspace.getPath("output/svt_sd_new.csv"));
+		log.info("Result will be saved to " + Testspace.getPath("output/svt_sd_new.csv"));
 	}
 
 	@After
@@ -76,23 +71,22 @@ public class OperationOnNewSD {
 		app.close();
 		result.close();
 	}
-	
+
 	@Test
 	public void operationOnNewSW() throws Exception {
 		String externalFile = prepareData("svt/sd_plain_50p.odp");
 		String pic = prepareData("svt/Sunset.jpg");
-		for(int i = 0; i < 1000; i++)
-		{
-//			Create a new SD
+		for (int i = 0; i < 1000; i++) {
+			// Create a new SD
 			app.dispatch("private:factory/simpress?slot=6686");
 			PresentationWizard.ok();
 			sleep(2);
-			
-//			Create a new slide
+
+			// Create a new slide
 			impress.menuItem("Insert->Slide").select();
 			sleep(2);
-			
-//			Insert a table
+
+			// Insert a table
 			app.dispatch(".uno:InsertTable", 3);
 			sleep(2);
 			NumberofCol.setText("5");
@@ -107,8 +101,8 @@ public class OperationOnNewSD {
 			impress.typeKeys("<ctrl end>");
 			impress.typeKeys("2");
 			sleep(2);
-			
-//			Insert a picture
+
+			// Insert a picture
 			impress.menuItem("Insert->Slide").select();
 			sleep(2);
 			impress.menuItem("Insert->Picture->From File...").select();
@@ -119,8 +113,8 @@ public class OperationOnNewSD {
 			sleep(5);
 			impress.typeKeys("<esc>");
 			sleep(2);
-			
-//			Insert Slides from External Sample files
+
+			// Insert Slides from External Sample files
 			impress.menuItem("Insert->File...").select();
 			sleep(2);
 			FilePicker_Path.setText(externalFile);
@@ -130,8 +124,8 @@ public class OperationOnNewSD {
 			sleep(2);
 			ActiveMsgBox.yes();
 			sleep(20);
-			
-//			Slide Screen Show Settings
+
+			// Slide Screen Show Settings
 			impress.menuItem("Slide Show->Slide Transition...").select();
 			sleep(2);
 			ImpressSlideTransitions.select("Uncover Up");
@@ -146,25 +140,24 @@ public class OperationOnNewSD {
 			sleep(70);
 			impress.typeKeys("<esc>");
 			sleep(5);
-			
-//			Save file and close
+
+			// Save file and close
 			String saveTo = "tempSD" + i + ".odp";
 			impress.menuItem("File->Save As...").select();
 			FileUtil.deleteFile(saveTo);
 			submitSaveDlg(saveTo);
-			if(ActiveMsgBox.exists())
-			{
+			if (ActiveMsgBox.exists()) {
 				ActiveMsgBox.yes();
 				sleep(2);
 			}
 			impress.menuItem("File->Close").select();
-			
+
 			HashMap<String, Object> perfData = SystemUtil.getProcessPerfData(pid);
 			String record = i + "," + System.currentTimeMillis() + "," + perfData.get("rss") + "," + perfData.get("pcpu");
-			LOG.info("Record: " + record);
+			log.info("Record: " + record);
 			result.println(record);
 			result.flush();
-			
+
 			sleep(3);
 		}
 	}

Modified: incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnNewSW.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnNewSW.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnNewSW.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnNewSW.java Thu Aug 30 09:27:21 2012
@@ -24,19 +24,9 @@
  */
 package testcase.gui.svt.sw;
 
-import static org.openoffice.test.vcl.Tester.sleep;
-import static testlib.gui.AppUtil.submitSaveDlg;
-import static testlib.gui.UIMap.ActiveMsgBox;
-import static testlib.gui.UIMap.Bullet;
-import static testlib.gui.UIMap.Change;
-import static testlib.gui.UIMap.InsertIndexDlg;
-import static testlib.gui.UIMap.StyleAndFormattingDlg;
-import static testlib.gui.UIMap.StyleAndFormattingList;
-import static testlib.gui.UIMap.SuggestionList;
-import static testlib.gui.UIMap.app;
-import static testlib.gui.UIMap.startcenter;
-import static testlib.gui.UIMap.writer;
-import static testlib.gui.UIMap.writer_FrameDlg;
+import static org.openoffice.test.vcl.Tester.*;
+import static testlib.gui.AppUtil.*;
+import static testlib.gui.UIMap.*;
 
 import java.io.FileOutputStream;
 import java.io.PrintStream;
@@ -47,19 +37,18 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 import org.openoffice.test.common.FileUtil;
+import org.openoffice.test.common.Logger;
 import org.openoffice.test.common.SystemUtil;
 import org.openoffice.test.common.Testspace;
 
-import testlib.gui.Log;
-
 public class OperationOnNewSW {
 	@Rule
-	public Log LOG = new Log();
-	
+	public Logger log = Logger.getLogger(this);
+
 	private PrintStream result = null;
-	
+
 	private String pid = null;
-	
+
 	/**
 	 * @throws java.lang.Exception
 	 */
@@ -68,9 +57,9 @@ public class OperationOnNewSW {
 		app.start(true);
 		result = new PrintStream(new FileOutputStream(Testspace.getFile("output/svt_sw_new.csv")));
 		HashMap<String, Object> proccessInfo = SystemUtil.findProcess(".*(soffice\\.bin|soffice.*-env).*");
-		pid = (String)proccessInfo.get("pid");
+		pid = (String) proccessInfo.get("pid");
 		result.println("Iterator,Time,Memory(KB),CPU(%)");
-		LOG.info("Result will be saved to " + Testspace.getPath("output/longrun.csv"));
+		log.info("Result will be saved to " + Testspace.getPath("output/longrun.csv"));
 	}
 
 	@After
@@ -78,18 +67,17 @@ public class OperationOnNewSW {
 		app.close();
 		result.close();
 	}
-	
+
 	@Test
 	public void operationOnNewSW() throws Exception {
-		for(int i = 0; i < 1000; i++)
-		{
+		for (int i = 0; i < 1000; i++) {
 			startcenter.menuItem("File->New->Text Document").select();
-			
-//	Input words (Duplicate Formatting) and set numbering and bullet.	
+
+			// Input words (Duplicate Formatting) and set numbering and bullet.
 			writer.typeKeys("this is a wonderful world");
 			writer.typeKeys("<enter>");
 			sleep(3);
-			writer.typeKeys("this is a beautiful world");			
+			writer.typeKeys("this is a beautiful world");
 			app.dispatch(".uno:SelectAll");
 			writer.menuItem("Format->Bullets and Numbering...").select();
 			sleep(3);
@@ -101,8 +89,8 @@ public class OperationOnNewSW {
 			writer.typeKeys("<ctrl end>");
 			writer.typeKeys("<enter>");
 			sleep(2);
-			
-// Word Spell Check
+
+			// Word Spell Check
 			writer.typeKeys("goood");
 			sleep(2);
 			writer.menuItem("Tools->Spelling and Grammar...").select();
@@ -112,9 +100,8 @@ public class OperationOnNewSW {
 			sleep(2);
 			ActiveMsgBox.no();
 			sleep(2);
-		
-			
-//	Create Header and Footer
+
+			// Create Header and Footer
 			writer.menuItem("Insert->Header->Default").select();
 			sleep(2);
 			writer.typeKeys("Header");
@@ -127,8 +114,8 @@ public class OperationOnNewSW {
 			sleep(2);
 			writer.typeKeys("<enter>");
 			sleep(2);
-			
-//	Insert Frame and change anchor
+
+			// Insert Frame and change anchor
 			writer.menuItem("Insert->Frame...").select();
 			sleep(2);
 			writer_FrameDlg.ok();
@@ -144,31 +131,27 @@ public class OperationOnNewSW {
 			sleep(2);
 			writer.typeKeys("<enter>");
 			sleep(2);
-			
-//	Insert TOC
-			for(int j = 0; j < 6; j++)
-			{
+
+			// Insert TOC
+			for (int j = 0; j < 6; j++) {
 				writer.typeKeys(String.valueOf(j + 1));
 				writer.typeKeys("<enter>");
 			}
 			writer.typeKeys("<ctrl home>");
-			for(int k = 0; k < 2; k++)
-			{
+			for (int k = 0; k < 2; k++) {
 				writer.typeKeys("<shift down>");
 			}
-			if(!StyleAndFormattingDlg.exists())
-			{
+			if (!StyleAndFormattingDlg.exists()) {
 				app.dispatch(".uno:DesignerDialog");
 				sleep(2);
 			}
-			
+
 			StyleAndFormattingList.doubleClick(0.5, 0.25);
 			sleep(2);
 			writer.typeKeys("<down>");
 			writer.typeKeys("<right>");
 			writer.typeKeys("<left>");
-			for(int k = 0; k < 2; k++)
-			{
+			for (int k = 0; k < 2; k++) {
 				writer.typeKeys("<shift down>");
 			}
 			StyleAndFormattingList.doubleClick(0.5, 0.3);
@@ -180,30 +163,27 @@ public class OperationOnNewSW {
 			InsertIndexDlg.ok();
 			sleep(2);
 			writer.typeKeys("<ctrl end>");
-			
 
-// Save File and close
+			// Save File and close
 			String saveTo = "temp" + i + ".odt";
 			writer.menuItem("File->Save As...").select();
 			FileUtil.deleteFile(saveTo);
 			submitSaveDlg(saveTo);
-			if(ActiveMsgBox.exists())
-			{
+			if (ActiveMsgBox.exists()) {
 				ActiveMsgBox.yes();
 				sleep(2);
 			}
-			
+
 			writer.menuItem("File->Close").select();
-			
+
 			HashMap<String, Object> perfData = SystemUtil.getProcessPerfData(pid);
 			String record = i + "," + System.currentTimeMillis() + "," + perfData.get("rss") + "," + perfData.get("pcpu");
-			LOG.info("Record: " + record);
+			log.info("Record: " + record);
 			result.println(record);
 			result.flush();
-			
+
 			sleep(3);
 		}
-		
-		
+
 	}
 }

Modified: incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnSample1.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnSample1.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnSample1.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnSample1.java Thu Aug 30 09:27:21 2012
@@ -24,10 +24,9 @@
  */
 package testcase.gui.svt.sw;
 
-import static org.openoffice.test.common.Testspace.prepareData;
-import static testlib.gui.AppUtil.submitOpenDlg;
-import static testlib.gui.UIMap.app;
-import static testlib.gui.UIMap.writer;
+import static org.openoffice.test.common.Testspace.*;
+import static org.openoffice.test.vcl.Tester.*;
+import static testlib.gui.AppUtil.*;
 import static testlib.gui.UIMap.*;
 
 import java.io.FileOutputStream;
@@ -39,21 +38,19 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 import org.openoffice.test.OpenOffice;
+import org.openoffice.test.common.Logger;
 import org.openoffice.test.common.SystemUtil;
 import org.openoffice.test.common.Testspace;
-import static org.openoffice.test.vcl.Tester.*;
-
-import testlib.gui.Log;
 
 public class OperationOnSample1 {
-	
+
 	@Rule
-	public Log LOG = new Log();
-	
+	public Logger log = Logger.getLogger(this);
+
 	private PrintStream result = null;
-	
+
 	private String pid = null;
-	
+
 	/**
 	 * @throws java.lang.Exception
 	 */
@@ -63,18 +60,15 @@ public class OperationOnSample1 {
 		app.start();
 		result = new PrintStream(new FileOutputStream(Testspace.getFile("output/svt_sw_sample1.csv")));
 		String processSoffice = null;
-		if(SystemUtil.isWindows())
-		{
+		if (SystemUtil.isWindows()) {
 			processSoffice = ".*soffice\\.exe.*";
-		}
-		else 
-		{
+		} else {
 			processSoffice = ".*soffice\\.bin.*";
 		}
 		HashMap<String, Object> proccessInfo = SystemUtil.findProcess(processSoffice);
-		pid = (String)proccessInfo.get("pid");
+		pid = (String) proccessInfo.get("pid");
 		result.println("Iterator,Time,Memory(KB),CPU(%)");
-		LOG.info("Result will be saved to " + Testspace.getPath("output/svt_sw_sample1.csv"));
+		log.info("Result will be saved to " + Testspace.getPath("output/svt_sw_sample1.csv"));
 	}
 
 	@After
@@ -82,12 +76,11 @@ public class OperationOnSample1 {
 		app.close();
 		result.close();
 	}
-	
+
 	@Test
-	public void operationOnSample1() throws Exception{
+	public void operationOnSample1() throws Exception {
 		String file = prepareData("svt/ScenarioDesign.odt");
-		for(int i = 0; i < 1000; i++)
-		{
+		for (int i = 0; i < 1000; i++) {
 			System.out.println("This is the " + i + " round");
 			app.dispatch(".uno:Open");
 			submitOpenDlg(file);
@@ -95,12 +88,12 @@ public class OperationOnSample1 {
 			writer.typeKeys("<down>");
 			writer.typeKeys("<down>");
 			sleep(2);
-			
+
 			writer.menuItem("Table->Split Cells").select();
 			sleep(2);
 			Writer_SplitCellDlg.ok();
 			sleep(2);
-			
+
 			writer.typeKeys("<shift down>");
 			writer.typeKeys("<shift down>");
 			writer.typeKeys("<shift down>");
@@ -109,33 +102,33 @@ public class OperationOnSample1 {
 			sleep(2);
 			writer.menuItem("Table->Merge Cells").select();
 			sleep(2);
-			
+
 			writer.typeKeys("<enter>");
-//			writer.menuItem("Table->Insert->Rows...").select();
+			// writer.menuItem("Table->Insert->Rows...").select();
 			app.dispatch(".uno:InsertRowDialog");
 			Writer_InsertRowsDlg.ok();
 			sleep(2);
-			
+
 			writer.menuItem("Table->Delete->Rows").select();
 			sleep(2);
-			
+
 			app.dispatch(".uno:InsertColumnDialog");
 			Writer_InsertColumnsDlg.ok();
 			sleep(2);
-			
+
 			writer.menuItem("Table->Delete->Columns").select();
 			sleep(2);
-			
+
 			writer.menuItem("File->Close").select();
 			ActiveMsgBox.no();
 			sleep(2);
-			
+
 			HashMap<String, Object> perfData = SystemUtil.getProcessPerfData(pid);
 			String record = i + "," + System.currentTimeMillis() + "," + perfData.get("rss") + "," + perfData.get("pcpu");
-			LOG.info("Record: " + record);
+			log.info("Record: " + record);
 			result.println(record);
 			result.flush();
-			
+
 			sleep(3);
 		}
 	}

Modified: incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnSample2.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnSample2.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnSample2.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testcase/gui/svt/sw/OperationOnSample2.java Thu Aug 30 09:27:21 2012
@@ -24,10 +24,9 @@
  */
 package testcase.gui.svt.sw;
 
-import static org.openoffice.test.common.Testspace.prepareData;
-import static testlib.gui.AppUtil.submitOpenDlg;
-import static testlib.gui.UIMap.app;
-import static testlib.gui.UIMap.writer;
+import static org.openoffice.test.common.Testspace.*;
+import static org.openoffice.test.vcl.Tester.*;
+import static testlib.gui.AppUtil.*;
 import static testlib.gui.UIMap.*;
 
 import java.io.FileOutputStream;
@@ -39,21 +38,19 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 import org.openoffice.test.OpenOffice;
+import org.openoffice.test.common.Logger;
 import org.openoffice.test.common.SystemUtil;
 import org.openoffice.test.common.Testspace;
-import static org.openoffice.test.vcl.Tester.*;
-
-import testlib.gui.Log;
 
 public class OperationOnSample2 {
-	
+
 	@Rule
-	public Log LOG = new Log();
-	
+	public Logger log = Logger.getLogger(this);
+
 	private PrintStream result = null;
-	
+
 	private String pid = null;
-	
+
 	/**
 	 * @throws java.lang.Exception
 	 */
@@ -63,18 +60,15 @@ public class OperationOnSample2 {
 		app.start();
 		result = new PrintStream(new FileOutputStream(Testspace.getFile("output/svt_sw_sample2.csv")));
 		String processSoffice = null;
-		if(SystemUtil.isWindows())
-		{
+		if (SystemUtil.isWindows()) {
 			processSoffice = ".*soffice\\.exe.*";
-		}
-		else 
-		{
+		} else {
 			processSoffice = ".*soffice\\.bin.*";
 		}
 		HashMap<String, Object> proccessInfo = SystemUtil.findProcess(processSoffice);
-		pid = (String)proccessInfo.get("pid");
+		pid = (String) proccessInfo.get("pid");
 		result.println("Iterator,Time,Memory(KB),CPU(%)");
-		LOG.info("Result will be saved to " + Testspace.getPath("output/svt_sw_sample2.csv"));
+		log.info("Result will be saved to " + Testspace.getPath("output/svt_sw_sample2.csv"));
 	}
 
 	@After
@@ -82,20 +76,19 @@ public class OperationOnSample2 {
 		app.close();
 		result.close();
 	}
-	
+
 	@Test
 	public void operationOnSample2() throws Exception {
 		String file = prepareData("svt/complex.odt");
 		String pic = prepareData("svt/Sunset.jpg");
-		
-		for(int i = 0; i < 1000; i++)
-		{
+
+		for (int i = 0; i < 1000; i++) {
 			System.out.println("This is the " + i + " round");
 			app.dispatch(".uno:Open");
 			submitOpenDlg(file);
 			writer.waitForExistence(20, 2);
-			
-//	Set Paragraph properties		
+
+			// Set Paragraph properties
 			app.dispatch(".uno:SelectAll");
 			sleep(2);
 			writer.menuItem("Format->Paragraph...").select();
@@ -108,8 +101,8 @@ public class OperationOnSample2 {
 			sleep(2);
 			writer.typeKeys("<ctrl end>");
 			sleep(5);
-			
-// Insert Picture from file
+
+			// Insert Picture from file
 			writer.menuItem("Insert->Picture->From File...").select();
 			sleep(2);
 			FilePicker_Path.setText(pic);
@@ -118,10 +111,10 @@ public class OperationOnSample2 {
 			sleep(5);
 			writer.typeKeys("<esc>");
 			sleep(2);
-			
-// Insert OLE Object
-//			writer.menuItem("Insert->Object->OLE Object...").select();
-//			sleep(2);
+
+			// Insert OLE Object
+			// writer.menuItem("Insert->Object->OLE Object...").select();
+			// sleep(2);
 			app.dispatch(".uno:InsertObject");
 			sleep(2);
 			InsertObject.ok();
@@ -130,8 +123,8 @@ public class OperationOnSample2 {
 			sleep(5);
 			typeKeys("<esc>");
 			sleep(5);
-				
-// Insert Chart
+
+			// Insert Chart
 			writer.menuItem("Insert->Object->Chart...").select();
 			sleep(5);
 			typeKeys("<esc>");
@@ -141,17 +134,17 @@ public class OperationOnSample2 {
 			typeKeys("<esc>");
 			sleep(5);
 
-// Close file
+			// Close file
 			writer.menuItem("File->Close").select();
 			ActiveMsgBox.no();
 			sleep(2);
 
 			HashMap<String, Object> perfData = SystemUtil.getProcessPerfData(pid);
 			String record = i + "," + System.currentTimeMillis() + "," + perfData.get("rss") + "," + perfData.get("pcpu");
-			LOG.info("Record: " + record);
+			log.info("Record: " + record);
 			result.println(record);
 			result.flush();
-			
+
 			sleep(3);
 		}
 	}

Modified: incubator/ooo/trunk/main/test/testgui/source/testcase/gui/sw/table/Table.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testcase/gui/sw/table/Table.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testcase/gui/sw/table/Table.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testcase/gui/sw/table/Table.java Thu Aug 30 09:27:21 2012
@@ -19,31 +19,30 @@
  * 
  *************************************************************/
 
-
-
 /**
  * 
  */
 package testcase.gui.sw.table;
 
+import static org.junit.Assert.*;
+import static org.openoffice.test.vcl.Tester.*;
 import static testlib.gui.AppUtil.*;
 import static testlib.gui.UIMap.*;
-import static org.junit.Assert.*;
+
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
+import org.openoffice.test.common.Logger;
 import org.openoffice.test.common.SystemUtil;
 
-import testlib.gui.Log;
-
 /**
  *
  */
 public class Table {
 
 	@Rule
-	public Log LOG = new Log();
+	public Logger log = Logger.getLogger(this);
 
 	@Before
 	public void setUp() throws Exception {
@@ -52,17 +51,18 @@ public class Table {
 
 	@After
 	public void tearDown() throws Exception {
-		
+
 	}
 
 	/**
 	 * Test convert table to text in text document
+	 * 
 	 * @throws Exception
 	 */
 	@Test
-	public void testConvertTableToText() throws Exception{
+	public void testConvertTableToText() throws Exception {
 
-		//Create a new text document
+		// Create a new text document
 		app.dispatch("private:factory/swriter");
 
 		// Insert a table and input some data
@@ -75,14 +75,18 @@ public class Table {
 		// Convert table to text
 		app.dispatch(".uno:ConvertTableToText");
 		assertTrue("Convert Table to Text dialog pop up", writer_ConvertTableToTextDlg.exists());
-//		typeKeys("<enter>");
-		writer_ConvertTableToTextDlg.ok();	// "Enter" does not work on linux
+		// typeKeys("<enter>");
+		writer_ConvertTableToTextDlg.ok(); // "Enter" does not work on linux
 
 		// Verify if text is converted successfully
 		app.dispatch(".uno:SelectAll");
 		app.dispatch(".uno:Copy");
 		if (SystemUtil.isWindows())
-			assertEquals("Converted text", "1\t2\r\n3\t4\r\n", app.getClipboard());	// in windows, \n is \r\n
+			assertEquals("Converted text", "1\t2\r\n3\t4\r\n", app.getClipboard()); // in
+																					// windows,
+																					// \n
+																					// is
+																					// \r\n
 		else
 			assertEquals("Converted text", "1\t2\n3\t4\n", app.getClipboard());
 	}

Modified: incubator/ooo/trunk/main/test/testgui/source/testlib/gui/AppUtil.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testlib/gui/AppUtil.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testlib/gui/AppUtil.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testlib/gui/AppUtil.java Thu Aug 30 09:27:21 2012
@@ -19,9 +19,8 @@
  * 
  *************************************************************/
 
-
-
 package testlib.gui;
+
 import static testlib.gui.UIMap.*;
 
 import org.openoffice.test.common.Condition;
@@ -53,10 +52,10 @@ public class AppUtil extends Tester {
 			setCustomizedShortcut("undo", "command", "z");
 			setCustomizedShortcut("redo", "command", "shift", "z");
 		} else if (SystemUtil.isLinux()) {
-			
-		} 
+
+		}
 	}
-	
+
 	public static void typeKeys(String keys) {
 		Tester.typeKeys(keys);
 	}
@@ -64,27 +63,25 @@ public class AppUtil extends Tester {
 	public static void openStartcenter() {
 		if (startcenter.exists())
 			return;
-		
+
 		if (SystemUtil.isMac()) {
 			SystemUtil.execScript("osascript -e 'tell app \"OpenOffice.org\" to activate'");
 			typeKeys("<command n>");
 		}
-		
+
 	}
-	
 
 	public static void submitOpenDlg(String path) {
 		FilePicker_Path.setText(path);
 		FilePicker_Open.click();
 		sleep(1);
 	}
-	
 
 	public static void submitSaveDlg(String path) {
 		FileSave_Path.setText(path);
-		
+
 		String extName = FileUtil.getFileExtName(path).toLowerCase();
-		
+
 		String[] filters = FileSave_FileType.getItemsText();
 		int i = 0;
 		for (; i < filters.length; i++) {
@@ -97,12 +94,12 @@ public class AppUtil extends Tester {
 		}
 		if (i == filters.length)
 			throw new RuntimeException("Can't find the supported doc format!");
-		
+
 		FileSave_FileType.select(i);
 		FileSave_Save.click();
 		sleep(1);
 	}
-	
+
 	public static void submitSaveDlg(String path, String ext) {
 		FileSave_Path.setText(path);
 		if (ext != null) {
@@ -120,10 +117,10 @@ public class AppUtil extends Tester {
 			if (i == filters.length)
 				throw new RuntimeException("Can't find the supported doc format!");
 		}
-		FileSave_FileType.click();	
+		FileSave_FileType.click();
 		sleep(1);
 	}
-	
+
 	public static void handleBlocker(final VclWindow... windows) {
 		new Condition() {
 			@Override
@@ -138,19 +135,19 @@ public class AppUtil extends Tester {
 						}
 					}
 				}
-				
+
 				boolean shown = false;
-		
-				for(VclWindow w : windows) {
+
+				for (VclWindow w : windows) {
 					if (w.exists()) {
 						shown = true;
 						break;
 					}
 				}
-				
+
 				if (!shown)
 					return false;
-				
+
 				if (ActiveMsgBox.exists(2)) {
 					try {
 						ActiveMsgBox.ok();
@@ -161,10 +158,10 @@ public class AppUtil extends Tester {
 						}
 					}
 				}
-				
+
 				return true;
 			}
-			
-		}.waitForTrue("Time out wait window to be active.",  120, 2);
+
+		}.waitForTrue("Time out wait window to be active.", 120, 2);
 	}
 }

Modified: incubator/ooo/trunk/main/test/testgui/source/testlib/gui/CalcUtil.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testlib/gui/CalcUtil.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testlib/gui/CalcUtil.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testlib/gui/CalcUtil.java Thu Aug 30 09:27:21 2012
@@ -19,8 +19,6 @@
  * 
  *************************************************************/
 
-
-
 package testlib.gui;
 
 import static org.openoffice.test.vcl.Tester.*;
@@ -30,13 +28,10 @@ import java.lang.reflect.Array;
 import java.util.StringTokenizer;
 import java.util.logging.Logger;
 
-
-
-
 public class CalcUtil {
-	
+
 	private static Logger LOG = Logger.getLogger(CalcUtil.class.getName());
-	
+
 	/**
 	 * Select a range.
 	 * 
@@ -61,9 +56,10 @@ public class CalcUtil {
 		if (cell != null)
 			selectRange(cell);
 		String caption = SC_InputBar_Input.getCaption();
-		//Fix: When formulaEdit's caption is blank, the hook will return the document window's caption
+		// Fix: When formulaEdit's caption is blank, the hook will return the
+		// document window's caption
 		// So if it's document window caption, return ""
-		return caption.contains("[12479]") ? "": caption;
+		return caption.contains("[12479]") ? "" : caption;
 	}
 
 	/**
@@ -81,52 +77,52 @@ public class CalcUtil {
 		if (content.endsWith("\r\n"))
 			content = content.substring(0, content.length() - 2);
 		else if (content.endsWith("\n"))
-				content = content.substring(0, content.length() - 1);
-		
+			content = content.substring(0, content.length() - 1);
+
 		return content;
 	}
 
-
 	/**
-	 * convert the format of column number to integer 
-	 * e.g.
-	 * A -> 1
-	 * AA -> 27
-	 * AMJ -> 1024
+	 * convert the format of column number to integer e.g. A -> 1 AA -> 27 AMJ
+	 * -> 1024
+	 * 
 	 * @param no
 	 * @return
 	 */
 	public static int toIntColumnNo(String no) {
 		int len = no.length();
 		int ret = 0;
-		for(int i = 0; i < len; i++) {
+		for (int i = 0; i < len; i++) {
 			char c = no.charAt(len - i - 1);
 			ret += Math.pow(26, i) * (c - 'A' + 1);
 		}
-		
+
 		return ret;
 	}
-	
+
 	/**
-	 * Convert the format of column number to char 
+	 * Convert the format of column number to char
+	 * 
 	 * @param no
 	 * @return
 	 */
-	public static String toCharColumnNo(int no){
+	public static String toCharColumnNo(int no) {
 		String ret = "";
 		int f = 0;
 		do {
 			f = (no - 1) / 26;
 			int s = (no - 1) % 26;
-			ret = (char)('A' + s) + ret;
+			ret = (char) ('A' + s) + ret;
 			no = f;
 		} while (f != 0);
 		return ret;
 	}
-	
+
 	/**
 	 * Parse location string into integer values
-	 * @param loc e.g. A1
+	 * 
+	 * @param loc
+	 *            e.g. A1
 	 * @return
 	 */
 	public static int[] parseLocation(String loc) {
@@ -136,17 +132,19 @@ public class CalcUtil {
 			if (c >= '0' && c <= '9')
 				break;
 		}
-	
+
 		String col = loc.substring(0, i);
 		String row = loc.substring(i);
 		int sC = toIntColumnNo(col);
 		int sR = Integer.parseInt(row);
-		return new int[]{sC, sR};
+		return new int[] { sC, sR };
 	}
-	
+
 	/**
 	 * Parse range string into integer values
-	 * @param range e.g. A3:F9
+	 * 
+	 * @param range
+	 *            e.g. A3:F9
 	 * @return
 	 */
 	public static int[] parseRange(String range) {
@@ -154,7 +152,7 @@ public class CalcUtil {
 		if (dotIndex != -1) {
 			range = range.substring(dotIndex + 1);
 		}
-		
+
 		String[] locs = range.split(":");
 		int[] ret = new int[4];
 		int[] start = parseLocation(locs[0]);
@@ -168,25 +166,25 @@ public class CalcUtil {
 			ret[2] = end[0];
 			ret[3] = end[1];
 		}
-		
+
 		return ret;
 	}
 
 	/**
 	 * Get the text at the given cells. If the cell is a formula, return the
-	 * result rather than the formula.
-	 * Note:
+	 * result rather than the formula. Note:
 	 * 
-	 * @param range e.g. A3:D9
+	 * @param range
+	 *            e.g. A3:D9
 	 * @return
 	 */
 	public static String[][] getCellTexts(String range) {
 		selectRange(range);
 		int[] intRange = parseRange(range);
-		int rowCount = intRange[3]-intRange[1]+1;
-		int colCount = intRange[2]-intRange[0]+1;
+		int rowCount = intRange[3] - intRange[1] + 1;
+		int colCount = intRange[2] - intRange[0] + 1;
 		String[][] texts = new String[rowCount][colCount];
-		
+
 		app.setClipboard("$$$$");
 		typeKeys("<$copy>");
 		sleep(1);
@@ -194,7 +192,7 @@ public class CalcUtil {
 		StringTokenizer tokenizer = new StringTokenizer(text, "\"\t\n", true);
 		int state = 0;
 		String cellContent = "";
-		int r=0, c = 0;
+		int r = 0, c = 0;
 		while (tokenizer.hasMoreTokens()) {
 			String token = tokenizer.nextToken();
 			switch (state) {
@@ -212,7 +210,7 @@ public class CalcUtil {
 					cellContent = "";
 					c = 0;
 					r++;
-				} else{
+				} else {
 					cellContent += token;
 				}
 				break;
@@ -225,7 +223,7 @@ public class CalcUtil {
 				break;
 			}
 		}
-		
+
 		LOG.info("Text of range [" + range + "]:\n" + arrayToString(texts));
 		return texts;
 	}
@@ -233,12 +231,12 @@ public class CalcUtil {
 	private static String arrayToString(Object array) {
 		if (array == null)
 			return "null";
-		if (!array.getClass().isArray()) 
+		if (!array.getClass().isArray())
 			return array.toString();
-			
+
 		int len = Array.getLength(array);
 		String ret = "{";
-		for (int i= 0; i < len; i++) {
+		for (int i = 0; i < len; i++) {
 			Object el = Array.get(array, i);
 			if (el == null) {
 				ret += "null";
@@ -247,10 +245,10 @@ public class CalcUtil {
 			} else {
 				ret += "\"" + el + "\"";
 			}
-			
+
 			if (i + 1 != len)
 				ret += ",";
-			
+
 		}
 		ret += "}";
 		return ret;

Modified: incubator/ooo/trunk/main/test/testgui/source/testlib/gui/ImpressUtil.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testlib/gui/ImpressUtil.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testlib/gui/ImpressUtil.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testlib/gui/ImpressUtil.java Thu Aug 30 09:27:21 2012
@@ -19,23 +19,22 @@
  * 
  *************************************************************/
 
-
-
 package testlib.gui;
 
+import static testlib.gui.UIMap.*;
+
 import org.openoffice.test.vcl.widgets.VclWindow;
 
-import static testlib.gui.UIMap.*;
 public class ImpressUtil {
-	
+
 	public static VclWindow getCurView() {
-		VclWindow[] views = new VclWindow[]{impress, ImpressOutline, ImpressSlideSorter, ImpressHandout};
-		for(VclWindow w : views) {
+		VclWindow[] views = new VclWindow[] { impress, ImpressOutline, ImpressSlideSorter, ImpressHandout };
+		for (VclWindow w : views) {
 			if (w.exists()) {
 				return w;
 			}
 		}
-		
+
 		return null;
 	}
 }

Modified: incubator/ooo/trunk/main/test/testgui/source/testlib/gui/UIMap.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testlib/gui/UIMap.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testlib/gui/UIMap.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testlib/gui/UIMap.java Thu Aug 30 09:27:21 2012
@@ -19,9 +19,8 @@
  * 
  *************************************************************/
 
-
-
 package testlib.gui;
+
 import java.io.File;
 
 import org.openoffice.test.OpenOffice;
@@ -42,40 +41,40 @@ import org.openoffice.test.vcl.widgets.V
 import org.openoffice.test.vcl.widgets.VclTabControl;
 import org.openoffice.test.vcl.widgets.VclTabPage;
 import org.openoffice.test.vcl.widgets.VclToolBox;
-import org.openoffice.test.vcl.widgets.VclWindow;
 import org.openoffice.test.vcl.widgets.VclTreeListBox;
+import org.openoffice.test.vcl.widgets.VclWindow;
 
 /**
- * Define all UI controls in the class.
- * One control should be defined once and only once.
- *
+ * Define all UI controls in the class. One control should be defined once and
+ * only once.
+ * 
  */
 public class UIMap {
 	private static IDList idList = new IDList(new File("./hid"));
 	public static final VclMessageBox ActiveMsgBox = new VclMessageBox(Constant.UID_ACTIVE);
 	public static final VclMessageBox MsgBox_AdditionalRowsNotSaved = new VclMessageBox(Constant.UID_ACTIVE, "Additional rows were not saved.");
 	public static final VclTabControl ActiveTabControl = new VclTabControl(Constant.UID_ACTIVE);
-	
+
 	public static VclEditBox editbox(String id) {
 		return new VclEditBox(idList.getId(id));
 	}
-	
+
 	public static VclControl control(String id) {
 		return new VclControl(idList.getId(id));
 	}
-	
+
 	public static VclWindow window(String id) {
 		return new VclWindow(idList.getId(id));
 	}
-	
+
 	public static VclDialog dialog(String id) {
 		return new VclDialog(idList.getId(id));
 	}
-	
+
 	public static VclTabPage tabpage(String id) {
 		return new VclTabPage(idList.getId(id));
 	}
-	
+
 	public static VclListBox listbox(String id) {
 		return new VclListBox(idList.getId(id));
 	}
@@ -83,11 +82,11 @@ public class UIMap {
 	public static VclComboBox combobox(String id) {
 		return new VclComboBox(idList.getId(id));
 	}
-	
+
 	public static VclToolBox toolbox(String id) {
 		return new VclToolBox(idList.getId(id));
 	}
-	
+
 	public static VclButton button(String id) {
 		return new VclButton(idList.getId(id));
 	}
@@ -95,27 +94,27 @@ public class UIMap {
 	public static VclMessageBox msgbox(String text) {
 		return new VclMessageBox(idList.getId("UID_ACTIVE"), text);
 	}
-	
+
 	public static VclMenuItem menuItem(String text) {
 		return new VclMenuItem(text);
 	}
-		
+
 	public static VclStatusBar statusbar(String id) {
 		return new VclStatusBar(idList.getId(id));
 	}
-	
-	public static VclField field(String id){
+
+	public static VclField field(String id) {
 		return new VclField(idList.getId(id));
 	}
-	
-	public static VclDockingWin dockingwin(String id){
+
+	public static VclDockingWin dockingwin(String id) {
 		return new VclDockingWin(idList.getId(id));
 	}
-	
+
 	public static VclTreeListBox tree(String id) {
 		return new VclTreeListBox(idList.getId(id));
 	}
-	
+
 	public static final OpenOffice oo = new OpenOffice(null);
 	public static final VclApp app = VclApp.getDefault();
 	public static final VclWindow writer = window("SW_HID_EDIT_WIN");
@@ -214,7 +213,8 @@ public class UIMap {
 	public static final VclButton math_ElementsUnaryBinaryPlus = button("STARMATH_HID_SMA_PLUSX");
 	public static final VclControl MacroWarningOK = control("Ok");
 	public static final VclTreeListBox OptionsDlgList = tree("CUI_HID_OFADLG_TREELISTBOX");
-//	public static final VclListBox OptionsDlgList = listbox("CUI_HID_OFADLG_TREELISTBOX");
+	// public static final VclListBox OptionsDlgList =
+	// listbox("CUI_HID_OFADLG_TREELISTBOX");
 	public static final VclDialog OptionsDlg = dialog("CUI_HID_OFADLG_OPTIONS_TREE");
 	public static final VclButton OptionsDlg_MacroSecurityButton = button("cui:PushButton:RID_SVXPAGE_INET_SECURITY:PB_SEC_MACROSEC");
 	public static final VclControl MacroSecurityDlg = control("XMLSECURITY_HID_XMLSEC_TP_SECLEVEL");
@@ -223,7 +223,8 @@ public class UIMap {
 	public static final VclDialog writer_ConvertTableToTextDlg = dialog(".uno:ConvertTableText");
 	public static final VclWindow writer_Navigator = window("SW_HID_NAVIGATION_PI");
 	public static final VclListBox writer_NavigatorList = listbox("SW_HID_NAVIGATOR_TREELIST");
-//	public static final VclControl writer_FrameDlg = control("SW_HID_FRM_STD");
+	// public static final VclControl writer_FrameDlg =
+	// control("SW_HID_FRM_STD");
 	public static final VclDialog writer_FrameDlg = dialog("SW_HID_FRM_STD");
 	public static final VclField SC_NumberOfColumnsRowsToInsert = field("1502452023");
 	public static final VclDialog SC_InsertColumnsRowsdialog = dialog("26166");
@@ -370,7 +371,7 @@ public class UIMap {
 	public static final VclButton ChangeAll = button("CUI_HID_SPLDLG_BUTTON_CHANGEALL");
 	public static final VclButton AutoCorrect = button("cui:PushButton:RID_SVXDLG_SPELLCHECK:PB_AUTOCORR");
 	public static final VclButton Close = button("CUI_HID_SPLDLG_BUTTON_CLOSE");
-	
+
 	// Presentation:"Table Property" dialog
 	public static final VclButton impress_WizardDlg_Next = button("sd:PushButton:DLG_ASS:BUT_NEXT");
 	public static final VclListBox Area_Fill_Color = listbox("cui:ListBox:RID_SVXPAGE_AREA:LB_COLOR");
@@ -412,26 +413,26 @@ public class UIMap {
 	public static final VclToolBox Textbox_Toolbar = toolbox(".HelpId:textbar");
 	public static final VclButton SD_InsertTextboxButtonOnToolbar = button(".uno:Text");
 	public static final VclButton SD_FormatArea = button(".uno:FormatArea");
-	
-	//Writer:Style and Formatting List
+
+	// Writer:Style and Formatting List
 	public static final VclControl StyleAndFormattingList = control("SFX2_HID_TEMPLATE_FMT");
 	public static final VclListBox StyleFilterList = listbox("SFX2_HID_TEMPLATE_FILTER");
 	public static final VclDockingWin StyleAndFormattingDlg = dockingwin(".uno:DesignerDialog");
-	
-	//Writer:Insert Index and Table Dialog
+
+	// Writer:Insert Index and Table Dialog
 	public static final VclDialog InsertIndexDlg = dialog("SW_HID_TP_TOX_SELECT");
-	
-	//Writer:Split Cell Dialog
+
+	// Writer:Split Cell Dialog
 	public static final VclDialog Writer_SplitCellDlg = dialog("cui:ModalDialog:RID_SVX_SPLITCELLDLG");
-	
-	//Writer:Insert Rows/Columns Dialog
+
+	// Writer:Insert Rows/Columns Dialog
 	public static final VclDialog Writer_InsertRowsDlg = dialog(".uno:InsertRowDialog");
 	public static final VclField Writer_InsertNum = field("cui:NumericField:DLG_INS_ROW_COL:ED_COUNT");
 	public static final VclButton Writer_InsertBefore = button("cui:RadioButton:DLG_INS_ROW_COL:CB_POS_BEFORE");
 	public static final VclButton Writer_InsertAfter = button("cui:RadioButton:DLG_INS_ROW_COL:CB_POS_AFTER");
 	public static final VclDialog Writer_InsertColumnsDlg = dialog(".uno:InsertColumnDialog");
-	
-	//Writer:Alignment TabPage of Paragraph format
+
+	// Writer:Alignment TabPage of Paragraph format
 	public static final VclTabPage AlignmentTabPage = tabpage("CUI_HID_FORMAT_PARAGRAPH_ALIGN");
 	public static final VclButton Left = button("cui:RadioButton:RID_SVXPAGE_ALIGN_PARAGRAPH:BTN_LEFTALIGN");
 	public static final VclButton Right = button("cui:RadioButton:RID_SVXPAGE_ALIGN_PARAGRAPH:BTN_RIGHTALIGN");
@@ -441,8 +442,8 @@ public class UIMap {
 	public static final VclButton ExpandSingleWord = button("cui:CheckBox:RID_SVXPAGE_ALIGN_PARAGRAPH:CB_EXPAND");
 	public static final VclButton SnapToTextGrid = button("cui:CheckBox:RID_SVXPAGE_ALIGN_PARAGRAPH:CB_SNAP");
 	public static final VclListBox VerticalAlignment = listbox("cui:ListBox:RID_SVXPAGE_ALIGN_PARAGRAPH:LB_VERTALIGN");
-	
-	//Writer: Insert Object Dialog
+
+	// Writer: Insert Object Dialog
 	public static final VclDialog InsertObject = dialog(".uno:InsertObject");
 	public static final VclButton NewObject = button("cui:RadioButton:MD_INSERT_OLEOBJECT:RB_NEW_OBJECT");
 	public static final VclButton ObjectFromFile = button("cui:RadioButton:MD_INSERT_OLEOBJECT:RB_OBJECT_FROMFILE");
@@ -451,25 +452,22 @@ public class UIMap {
 	public static final VclButton ObjectFileSearch = button("cui:PushButton:MD_INSERT_OLEOBJECT:BTN_FILEPATH");
 	public static final VclButton ObjectFileLink = button("cui:CheckBox:MD_INSERT_OLEOBJECT:CB_FILELINK");
 	public static final VclField NumberofCol = field("cui:NumericField:RID_SVX_NEWTABLE_DLG:NF_COLUMNS");
-	
-	//Presentation: Insert Table
+
+	// Presentation: Insert Table
 	public static final VclField NumberofRow = field("cui:NumericField:RID_SVX_NEWTABLE_DLG:NF_ROWS");
 	public static final VclDialog InsertSlideObjects = dialog("SD_HID_DLG_INSERT_PAGES_OBJS");
-	
-	//Presentation: Slide Transition Settings
+
+	// Presentation: Slide Transition Settings
 	public static final VclListBox ImpressSlideTransitions = listbox("SD_HID_SD_SLIDETRANSITIONPANE_LB_SLIDE_TRANSITIONS");
 	public static final VclListBox SlideShowSpeed = listbox("SD_HID_SD_SLIDETRANSITIONPANE_LB_SPEED");
 	public static final VclButton SlideAutoAfter = button("SD_HID_SD_SLIDETRANSITIONPANE_RB_ADVANCE_AUTO");
 	public static final VclButton ApplyToAllSlides = button("SD_HID_SD_SLIDETRANSITIONPANE_PB_APPLY_TO_ALL");
-	
-    //Spreadsheet: Standard Filter Dialog
+
+	// Spreadsheet: Standard Filter Dialog
 	public static final VclComboBox FilterValue1 = combobox("sc:ComboBox:RID_SCDLG_FILTER:ED_VAL1");
 	public static final VclDialog StandardFilterDlg = dialog(".uno:DataFilterStandardFilter");
-	
-	//Fontwork
+
+	// Fontwork
 	public static final VclDialog FontworkGalleryDlg = dialog("svx:ModalDialog:RID_SVX_MDLG_FONTWORK_GALLERY");
-	
-	
-	
 
 }

Modified: incubator/ooo/trunk/main/test/testgui/source/testsuite/gui/TestSampleAsMS2003.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testsuite/gui/TestSampleAsMS2003.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testsuite/gui/TestSampleAsMS2003.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testsuite/gui/TestSampleAsMS2003.java Thu Aug 30 09:27:21 2012
@@ -19,39 +19,32 @@
  * 
  *************************************************************/
 
-
-
 package testsuite.gui;
 
-import java.io.File;
 import java.util.ArrayList;
 import java.util.Collection;
 
-import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.junit.runners.Parameterized;
-import org.junit.runners.Suite;
 import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Suite;
 import org.junit.runners.Suite.SuiteClasses;
 
 import testcase.gui.TestSample;
 import testsuite.gui.TestSampleAsMS2003.SetParams;
 
 @RunWith(Suite.class)
-@SuiteClasses({SetParams.class, TestSample.class })
+@SuiteClasses({ SetParams.class, TestSample.class })
 public class TestSampleAsMS2003 {
 
 	@RunWith(Parameterized.class)
 	public static class SetParams {
 		@Parameters
-		public static Collection<Object[]>  data() {
+		public static Collection<Object[]> data() {
 			TestSample.repos = "../samples";
-    		TestSample.params = new String[][]{
-    			{".*\\.((docx)|(docm)|(dotx)|(dotm))$", "doc", "writer"},
-    			{".*\\.((xlsx)|(xltx)|(xlsm)|(xltm))$", "xls", "calc"}, 
-    			{".*\\.((pptx)|(pptm)|(potm)|(potx))$", "ppt", "impress"}
-    		};
-    		return new ArrayList<Object[]>();
+			TestSample.params = new String[][] { { ".*\\.((docx)|(docm)|(dotx)|(dotm))$", "doc", "writer" }, { ".*\\.((xlsx)|(xltx)|(xlsm)|(xltm))$", "xls", "calc" },
+					{ ".*\\.((pptx)|(pptm)|(potm)|(potx))$", "ppt", "impress" } };
+			return new ArrayList<Object[]>();
 		}
 	}
 }

Modified: incubator/ooo/trunk/main/test/testgui/source/testsuite/gui/TestSampleAsOriginal.java
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/test/testgui/source/testsuite/gui/TestSampleAsOriginal.java?rev=1378870&r1=1378869&r2=1378870&view=diff
==============================================================================
--- incubator/ooo/trunk/main/test/testgui/source/testsuite/gui/TestSampleAsOriginal.java (original)
+++ incubator/ooo/trunk/main/test/testgui/source/testsuite/gui/TestSampleAsOriginal.java Thu Aug 30 09:27:21 2012
@@ -19,8 +19,6 @@
  * 
  *************************************************************/
 
-
-
 package testsuite.gui;
 
 import java.util.ArrayList;
@@ -36,20 +34,17 @@ import testcase.gui.TestSample;
 import testsuite.gui.TestSampleAsOriginal.SetParams;
 
 @RunWith(Suite.class)
-@SuiteClasses({SetParams.class, TestSample.class })
+@SuiteClasses({ SetParams.class, TestSample.class })
 public class TestSampleAsOriginal {
 
 	@RunWith(Parameterized.class)
 	public static class SetParams {
 		@Parameters
-		public static Collection<Object[]>  data() {
+		public static Collection<Object[]> data() {
 			TestSample.repos = "../samples";
-    		TestSample.params = new String[][]{
-    			{".*\\.((odt)|(ott)|(sxw)|(stw)|(doc)|(dot))$", null, "writer"},
-    			{".*\\.((ods)|(ots)|(sxc)|(stc)|(xls)|(xlt))$", null, "calc"}, 
-    			{".*\\.((odp)|(otp)|(sxi)|(sti)|(ppt)|(pot))$", null, "impress"}
-    		};
-    		return new ArrayList<Object[]>();
+			TestSample.params = new String[][] { { ".*\\.((odt)|(ott)|(sxw)|(stw)|(doc)|(dot))$", null, "writer" },
+					{ ".*\\.((ods)|(ots)|(sxc)|(stc)|(xls)|(xlt))$", null, "calc" }, { ".*\\.((odp)|(otp)|(sxi)|(sti)|(ppt)|(pot))$", null, "impress" } };
+			return new ArrayList<Object[]>();
 		}
 	}
 }



Mime
View raw message