问题标签 [saucelabs]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
python - 什么是不推荐的方式来做`new.classobj(name,(base_class,),my_dict)`
我在 saucelabsexample.py
文件中找到了使用该import new
模块的以下代码片段。
但是阅读help(new)
显示该模块已被弃用。什么是不折旧的方法new.classobj(name, (base_class,), d)
java - 使用 Saucelabs 和 Appium 为 Android 应用程序配置 CI 测试
我正在尝试使用 maven android 插件创建我的 android 应用程序,以便在带有 Appium 的 Saucelabs 上自动运行我的集成测试。到目前为止,我尝试过的所有事情都只给了我错误“无法下载移动应用程序:c:\workspace\android\android-it..\android-app\target\android-app.apk”
我在我的集成测试 pom 文件中使用了以下配置的 sauceconnect:
我的 appium 测试配置是在我的 setup 方法中完成的,如下所示:
根据我在 Saucelabs 和 Appium 上阅读的所有内容,这应该允许我的 apk 在我运行 maven 构建时正确下载并运行,但是,如上所述,情况似乎并非如此。如果有人可以为我提供我所缺少的指针,我将不胜感激。
ios - Appium错误:起点不在屏幕范围内
我正在尝试使用 Appium(通过 SauceLabs)在 iOS 上运行 Web 应用程序的自动化测试,并且在下面详述的相对简单的测试用例中遇到了问题。
我在 Appium 日志中收到以下错误:
查看屏幕截图,有问题的元素确实出现在屏幕上。
在尝试使用以下方法单击它之前,我尝试滚动到该元素:
并通过javascript滚动到它似乎没有任何区别。似乎某些坐标被弄乱了,但我对 Appium 的工作原理知之甚少。
考试
我创建了一个测试指向的 jsFiddle HERE(此处仅供查看)。它有一组列在页面下方的字段。
我正在设置具有以下功能的 Web 驱动程序:
WebDriver 测试本身(用 C# 编写)如下所示:
您可以看到需要单击一个“序列”字段。只是尝试不同组合的一种方式。
为了说明这个问题,以下组合失败:
而这些很好:
任何帮助将不胜感激。
(日志)
Appium 日志的(希望)相关部分在这里:
java - 在 SauceLabs 上运行 Android WebDriver 测试
我正在尝试在 saucelabs 上运行带有 webdriver 的 android 模拟器来测试一些网页。这就是我正在使用的能力:
然而,这给了我一个错误:
我找到的所有教程和答案都包括安装 apk 的功能,这不是我需要的。
提前致谢。
python - Python- 使用代理(Browsermob)和远程 Webdriver
我正在尝试使用 Browsermob 代理检查网站上的网络流量。通过运行以下命令:我发现代理服务器拒绝连接:
“代理服务器拒绝连接” “firefox 被配置为使用拒绝连接的代理。”
我还没有找到在 python 中使用远程 webdriver 设置代理的示例。
远程和firefoxprofile的desired_capabilites分别为:
{'name': 'abdc', 'javascriptEnabled': True, 'idle-timeout': '25', 'command-timeout': '30', 'max-duration': '300', 'platform': ' Windows 7', 'browserName': 'firefox', 'version': '28', 'proxy': {'proxyType': 'MANUAL', 'sslProxy': 'localhost:9117', 'httpProxy': 'localhost: 9117'},'loggingPrefs':{'浏览器':'ALL'}}
{u'rotatable': False, u'takesScreenshot': True, u'acceptSslCerts': True, u'cssSelectorsEnabled': True, u'javascriptEnabled': True, u'databaseEnabled': True, u'locationContextEnabled': True, u'platform': u'Darwin', u'browserName': u'firefox', u'version': u'29.0.1', u'nativeEvents': False, u'applicationCacheEnabled': True, u'webStorageEnabled' :真,u'browserConnectionEnabled':真,u'handlesAlerts':真}
我看过这张票,上面说问题已解决;但似乎并非如此。
karma-runner - karma-sauce-launcher 断开每次测试运行,导致 IE 和 Safari 运行失败
几个月来,我一直在通过所涉及的每个组件的多个版本(karma、socket.io、sauce-connect)遇到这个确切的问题。目前我在 Karma 12.16 上运行。
基本上,当使用https://github.com/karma-runner/karma-sauce-launcher时,Safari 和 IE 浏览器会在每次测试运行时启动断开连接,从而导致仅部分测试运行。相关的业力日志是
我尝试将 browserNoActivityTimeout 增加到 60000,但这只会导致测试在 60 秒而不是 10 秒后失败。这些失败中的每一个都有以下内容:
根据浏览器的不同,有时它只会执行 50 个测试(Executed 50 of 94 DISCONNECTED),而在其他浏览器上它会执行所有测试,但仍被视为失败的测试运行。我从未见过 Chrome 或 Firefox 发生这种情况。
每次都在本地运行完全相同的 karma.conf 文件,没有任何问题。有没有人遇到过这个?我已经联系了 saucelabs 的支持,但他们开始坚持认为这是一个 karma-sauce-launcher 问题。
业力.conf:
linux - Saucelabs connect Linux - Not recognising the '-u' command
When trying to start up a tunnel using saucelabs connect, I'm using the standard command within the bin folder:
However, when I run it, an error is thrown saying:
I've tried on windows and it runs perfectly. Any ideas why it can't read the command?
javascript - 使用 JavaScript 中的 SauceLabs 在 iPhone 上进行 Selenium 测试
如何使用 Selenium 和 SauceLabs 为 Javascript 应用程序对 iPhone 进行端到端测试?我使用 wd.js 作为 Selenium 客户端库。
成为browser
的结果require("wd").remote(..., "promiseChain")
:
这导致:
然而,该组合直接取自https://saucelabs.com/platforms
一切都适用于所有其他组合,包括 Android 组合。
python - Not sure what is causing selenium timeouts
So recently tried to create a suite in python to run tests on some twitter share buttons. I used the "switch_to_frame" function to navigate into the iframe and select the button. Here is my code
My concern is that with multiple tests in the suite, sometimes selenium will timeout. Is there something wrong with my code or can it be improved? Ideally I'd like them to be as robust as possible and avoid timeouts. Thanks!
angularjs - Saucelabs 上的 websocket 立即断开连接(代码 1006)
我正在尝试为运行 websockets 的应用程序运行一些简单的测试。wesocket 连接突然停止,测试失败。这些测试根本与 websockets 无关。它们是关于单击页面上的一个按钮,该按钮仅在通过 websocket 接收到一些数据后才会出现。我附上了手动会话的屏幕截图。