我已经有一台 Windows PC,我在其中编写了我所有的 C# Selenium Webdriver 套件。从那里,运行测试将打开相应的浏览器,我可以根据需要调试或运行测试。有人可以让我知道一个合适的 native iPhone 应用程序相当于这个开发和调试环境吗?据我所知,可以从编程方面使用 iOS 驱动程序,但没有可以使用的附加模拟器——它纯粹是一个 API。我查看了 Appium 网站,但它看起来只能在 Mac 上运行(如果我错了请纠正我)而且我不确定它是为“黑盒测试”设计的还是我是否必须加载完整的 iPhone 应用程序首先项目到它并从那里建立测试套件。仅从网站上很难判断。因此,我们将不胜感激 - 特别是如果您之前使用过 iOS 驱动程序或 Appium。
最佳答案
坏消息是:
- 您需要一台装有 OSX 的机器来运行“iPhone 模拟器”。 Here's the general consensus on running the emulator on a hackintosh
这是不好的部分。这是好的部分:
From there, running tests will open up the appropriate browser and I can either debug or run the tests as required.
- Appium's Inspector将有助于成为您的调试工具,而 iOS 模拟器是您的“浏览器”
As far as I could tell, iOS driver can be used from a programming side but does not have an attached simulator that can be used - it's purely an API.
- 你有 1/2 正确。
- 没有附加的模拟器 - 它只是一个 REST 服务器。
- 这就是您可以用任何语言编写测试的原因。
- 他们有各种客户端库,可以更轻松地使用它们。 Here's the one for C#
I'm not sure it is designed for 'black box testing'
- Appium 的理念之一是“您不必修改您的应用程序即可对其进行测试”,所以是的,您无需了解任何有关系统内部结构的知识即可对其进行测试。
or whether I have to load the full iPhone app project into it first and build up the test suites from there.
如果你想在模拟器上运行它(你这样做),你需要一个应用程序的开发者版本(编译完整的 iPhone 应用程序项目)
因此,要么您的 CI 系统(Jenkins 等)为您提供 .ipa 或 .app 文件,要么您可以让客户端开发人员为您制作一个,或者您可以查看源代码并构建并运行使用 XCode。
Here's the setup guide on how to run your app with Appium, which covers the above two points.
Difficult to tell just from the website.
- 开始学习有点曲折 -- 文档也有点散乱。我建议阅读 this首先,然后开始在示例 iOS 项目(如 this Paint app)上运行检查器,然后是您实际尝试自动化的应用。
关于c# - 如何使用 Windows 添加到我的 c# Selenium Webdriver 套件以合并 native iPhone 应用程序测试,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24380443/