在同一台机器上打开多个 appium 服务器实例 [英] Opening multiple appium server Instances on same machine

查看:32
本文介绍了在同一台机器上打开多个 appium 服务器实例的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我可以在我的机器上同时启动 2 个 appium 服务器实例,以便我可以在连接到机器的 2 个不同设备上同时执行我的测试脚本吗?实际上,我正在尝试在连接到同一台 Windows 机器的 2 个设备上运行我的测试脚本.为此,我使用 TestNG 传递 Android 驱动程序 url 来启动会话.这个 url 将是动态的,因为 2 个设备将使用 2 个 Appium 服务器实例.我可以同时创建 2 个 Appium 服务器实例吗?如果是这样,我可以使用代码来创建这些实例,因为我不想使用 GUI 来启动它.

Can I start 2 appium server instances on my machine at the same time so that I can execute my test script simultaneously on 2 different devices connected to the machine? Actually what I'm trying is to run my test script on 2 devices connected to same windows machine. For this I am using TestNG to pass the Android Driver url to start session. This url will be dynamic as 2 devices will be using 2 Appium server instances. Can I create 2 instances of Appium server at same time? If so then can I use code to create those instances as I don't want to use GUI to start it.

推荐答案

这个问题已经有人提出并回答了(如果我没看错的话).

This question has already been asked and answer (if I am reading what you want correctly).

请参考如何在 MAC 机器上从命令提示符启动 Appium 服务器?

在 Windows 机器上应该有一个 appium 可执行文件,您可以使用命令行参数 --address 127.0.0.1 -p 4273

On a windows machine there should be an appium executable which you run with the command line arguments --address 127.0.0.1 -p 4273

本质上,您需要做的就是使用不同的端口进行测试.

In essence all you need to do is use a different port for your tests.

这篇关于在同一台机器上打开多个 appium 服务器实例的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆