|
import org.eclipse.hyades.execution.runtime.datapool.IDatapoolIterator;
import org.eclipse.hyades.execution.runtime.datapool.IDatapoolRecord;
import resources.Script1Helper;
import com.rational.test.ft.*;
import com.rational.test.ft.object.interfaces.*;
import com.rational.test.ft.object.interfaces.SAP.*;
import com.rational.test.ft.object.interfaces.WPF.*;
import com.rational.test.ft.object.interfaces.dojo.*;
import com.rational.test.ft.object.interfaces.siebel.*;
import com.rational.test.ft.object.interfaces.flex.*;
import com.rational.test.ft.object.interfaces.generichtmlsubdomain.*;
import com.rational.test.ft.script.*;
import com.rational.test.ft.value.*;
import com.rational.test.ft.vp.*;
import com.ibm.rational.test.ft.object.interfaces.sapwebportal.*;
/**
* Description : Functional Test Script
* @author Administrator
*/
public class Script1 extends Script1Helper
{
/**
* Script Name : <b>Script1</b>
* Generated : <b>2010-5-24 下午06:08:37</b>
* Description : Functional Test Script
* Original Host : WinNT Version 5.2 Build 3790 (S)
*
* @since 2010/05/24
* @author Administrator
*/
public void testMain(Object[] args)
{
DatapoolScriptSupport dpss = new DatapoolScriptSupport();
org.eclipse.hyades.execution.runtime.datapool.IDatapool dp;
java.io.File dpfile = new java.io.File("E:\\IBM\\rationalsdp\\MY\\Project1\\TestDatapool1.rftdp");
dp = dpss.dpFactory().load(dpfile, true);
IDatapoolIterator dpitr = dpss.dpFactory().open(dp,"");
dpitr.dpInitialize(dp);
startApp("http://192.168.7.18:9081/oa");
// HTML Browser
// Document: 通用办公业务系统: http://192.168.7.18:9081/oa/login.jsp
text_username().click(atPoint(39,4));
browser_htmlBrowser(document_通用办公业务系统(),DEFAULT_FLAGS).inputChars("xuehong");
text_password().click(atPoint(34,10));
browser_htmlBrowser(document_通用办公业务系统(),DEFAULT_FLAGS).inputChars("11111111");
button_请您单击系統登录按钮登录系Style().click();
// Document: 通用办公业务系统: http://192.168.7.18:9081/oa/index.htm
// Document: Untitled Document: http://192.168.7.18:9081/oa/frame.htm
// Document: 目录树: http://192.168.7.18:9081/oa/left.jsp
text_收发文管理().click(atPoint(18,5));
link_收文管理().click();
// Document: 目录树: http://192.168.7.18:9081/oa/left.jsp#
link_收文登记().click();
// Document: 无标题文档: http://192.168.7.18:9081/oa/documentmanager/inceptDocAction.do?method=search
button_登记button().click();
IDatapoolRecord dprec = dpitr.dpCurrent();
// Document: 收文管理: http://192.168.7.18:9081/oa/documentmanager/inceptDocAction.do?method=docTypeByRole&frowardFlag=3
text_acceptdocTitle().click(atPoint(35,20));
text_acceptdocTitle().setText(dprec.getCell(0).getStringValue());
text_acceptdocSendDept().click(atPoint(49,15));
text_acceptdocSendDept().setText(dprec.getCell(1).getStringValue());
button_保存button().click();
// Document: top: http://192.168.7.18:9081/oa/top.jsp
image_image3().click();
browser_htmlBrowser(document_通用办公业务系统(),MAY_EXIT).close();
}
} |
|