简体   繁体   English

是否可以使用espresso测试记录器测试多个应用程序?

[英]Is it possible to test multiple apps with espresso test recorder?

是否可以使用espresso测试记录器记录多个应用程序的测试,或者您是否需要使用UiAutomator手动编写这些测试的代码?

For background, see: 有关背景,请参阅:

The pair of tools should work to test an app's notifications, for instance. 例如,这对工具应该用于测试应用程序的通知。

But these docs don't discuss using the Espresso Test Recorder for multiple apps. 但是这些文档没有讨论将Espresso Test Recorder用于多个应用程序。 The test recorder is in beta and still developing. 测试记录器处于测试阶段且仍在开发中。

Suggestion: Try using Espresso Test Recorder to record actions and assertions within each app separately, then manually combine the two generated test programs. 建议:尝试使用Espresso Test Recorder分别记录每个应用程序中的操作和断言,然后手动组合两个生成的测试程序。

Please report back on lessons learned! 请报告经验教训!

Espresso uses current applications context, so it means that you cannot do things like checking sharingIntent, notifications or opening another app. Espresso使用当前的应用程序上下文,因此这意味着您无法执行检查sharingIntent,通知或打开其他应用程序等操作。

You can make tests for each of your aplications, then write bash/python script for running them together, but as you think you cannot test multiple apps using single record or 'manual' test case. 您可以为每个应用程序进行测试,然后编写bash / python脚本以便一起运行它们,但是您认为无法使用单个记录或“手动”测试用例测试多个应用程序。

I think that UiAtomator can make a thing as this a pure instrumentation testing framework, but I haven't used that yet. 我认为UiAtomator可以做一个纯粹的仪器测试框架,但我还没有使用它。

Hope it will help. 希望它会有所帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM