如何使用 nightwatch 测试移动网络应用程序?

How to test mobile web apps using nightwatch?

我已经在 nightwatch 中进行了一些 e2e 测试。我想 运行 为我的移动网络应用程序(不是本机应用程序)使用相同的脚本。有什么方法可以利用现有的脚本 运行 在移动网络应用程序上使用 nightwatch 吗?

恐怕你不能这样做,因为 NightwatchJS 除了基于 Web UI 自动化之外不支持任何东西。但是,您绝对可以尝试 WebdriverIO which supports mobile automation for both Android and iOS. You can find the sample projects here.

干杯!