c# - Auto accepting permissions when the dialogs are shown during Xamarin.UITest scenarios
问题描述
I'm using Specflow + Gherkin to automate UI Tests for my Xamarin native project, and I've seen that system dialogs are not represented in the REPL tree when they are encountered during a first-time run through. This is quite difficult for me to cover the app in many of it's use cases, as some of them involve displaying the right error messages. Is there a way to auto-accept permissions when they are encountered? AT this moment it is even difficult to tell if the permission dialogs are even popping up at all.
I've also noticed that we can use the keyboard to [Tab][Tab][Tab][Enter] to accept permissions, so how do I send this key sequence to the emulator using Xamarin.UITest? what are the workarounds others have tried?
I read something about Backdoors here, can this be used somehow? Any other suggestions?
解决方案
推荐阅读
- php - 在 foreach 循环中使用 dateTime 函数检查设置的日期是否大于当前日期
- javascript - JQuery - 随机“XML 解析错误:标签不匹配”
- c# - ef core 2.0 使用包含过滤器搜索多个列
- unit-testing - 测试 JavaFX ListView 项目选择
- javascript - Javascript 对象 - 使用数组值作为键
- java - 使 getLatLng 工作,但无法从响应中删除 ( )
- r - 在 R 3.5 中使用 read.table 的另外三个行
- python - 在 Django 中添加静态 html 页面
- python - Matplotlib 为面向对象调整 RectangularSelector
- vba - 搜索工作表,然后将列复制到另一个工作表