關注質量與體驗:電子商務與自動化測試(2)

發表于:2014-04-09來源:博客園作者:oscarxie點擊數: 標簽:電子商務
48 textFieldsList.get(2).sendKeys(Some@example.com); 49 driver.findElement(By.name(Save)).click(); 50 } 51 52 public class SwipeableWebDriver extends RemoteWebDriver implements HasTouchScreen { 53 pri

  48 textFieldsList.get(2).sendKeys("Some@example.com");

  49 driver.findElement(By.name("Save")).click();

  50 }

  51

  52 public class SwipeableWebDriver extends RemoteWebDriver implements HasTouchScreen {

  53 private RemoteTouchScreen touch;

  54

  55 public SwipeableWebDriver(URL remoteAddress, Capabilities desiredCapabilities) {

  56 super(remoteAddress, desiredCapabilities);

  57 touch = new RemoteTouchScreen(getExecuteMethod());

  58 }

  59

  60 public TouchScreen getTouch() {

  61 return touch;

  62 }

  63 }

  64 }

復制代碼

  6. 運行Test,注意AVD里的Android如果沒有解鎖需要先解鎖

  這時候我們可以看到AVD在運行了,

  同時Appium的命令行有對應的輸出

  7. 更多信息請參考Appium的Github

  https://github.com/appium/appium

  建議可以Clone下這個項目,在Sample-code文件夾下有示例

  https://github.com/appium/appium/tree/master/sample-code

  同時Testerhome發起翻譯活動的中文文檔也提交進去了

  https://github.com/appium/appium/tree/master/docs/cn

原文轉自:http://www.cnblogs.com/oscarxie/p/3488262.html

国产97人人超碰caoprom_尤物国产在线一区手机播放_精品国产一区二区三_色天使久久综合给合久久97