你可以用量角器和Appium一起来测试混合应用程序? [英] Can you use Protractor and Appium together to test hybrid apps?
问题描述
下面是我的方案。我有是建立在角JS顶部的网站。我能够用量角器网站自动化。但也有它的网站上进行时,会反映在Android和iOS设备特定的操作。
Here is my scenario. I have a website which is built on top of Angular JS. I am able to automate the website using protractor. However there are certain actions which when performed on website are reflected in Android and IOS devices.
下面是我想达到的目标。
Here's what I want to achieve.
运行在网站上我的测试中像我通常做的,但我想火命令还测试Android和iOS的应用程序
Run my tests on website like I normally do but I want to fire commands to test the android and ios app also
/*
For eg:
1. Change password on website using protractor
2. Launch android app and check if the password has been changed
3. Switch back to protractor tests for website
*/
it('Change password and check on IOS and Android device' , function()
{
changePasswordOnWeb();
OpenMobileAppInDeviceUsingAppium();
checNewkPasswordOnMobileApp();
});
这可能吗?如果你能指出我的任何教程?
Is it possible? If it is can you point me to any of the tutorials?
推荐答案
好像你可以使用它
测试混合应用
这自述将帮助您设置量角器与Appium - 的Android / Chrome和Android / Safari浏览器。这里是视频如何做的。也许你应该考虑SauceLabs选项too.I认为你可以在配置的功能部分指定平台要求iOS和Android设备。
This readme will help you to setup Protractor with Appium - Android/Chrome and Android/Safari. Here is video how-to. Maybe you should consider the SauceLabs option too.I think you can request iOS and Android devices by specifying the platform in the capabilities section of the config.
如果你不想使用SauceLabs你可以看看使用Selenium的网格功能。你可以为iOS和Android硒的司机,并把它们连接到你的量角器场景撞上了一个集中的Selenium服务器,你只需要改变的seleniumAddress在您的配置文件指向集中的服务器。
If you don't want to use SauceLabs you can look at using Selenium's Grid functionality. You can get Selenium drivers for iOS and Android and have them connect to a centralized Selenium server that your Protractor scenarios are ran against, you just change the seleniumAddress in your config file to point to the centralized server.
这篇关于你可以用量角器和Appium一起来测试混合应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!