有没有办法为 Espresso 测试禁用 FirebaseMessagingService?
有没有办法为 Espresso 测试禁用 FirebaseMessagingService
?或者以某种方式在 Espresso 测试中提供 FirebaseMessagingService
的其他实现。或者手动启用 FirebaseMessagingService
。
Is there a way to disable FirebaseMessagingService
for the Espresso test? Or somehow provide other implementation of FirebaseMessagingService
in Espresso tests. Or enable FirebaseMessagingService
manually.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我不确定我是否充分理解了这个问题。假设实现在测试执行期间给您带来了问题。在这种情况下,您可以使用接口包装它,并使用依赖项注入在 UI 测试中提供模拟实现。
I'm not sure I understood the question adequately. Suppose the implementation gives you a problem during the execution of the test. In that case, you can wrap it with an interface and, using dependencies injection, provide a mock implementation inside your UI tests.