2

我正在为我的 iPad 应用程序进行 UIAutomation 测试。当一个用户与其他用户共享文件时,会收到 APNS 通知。我需要查看那里有哪些通知,然后点击这些通知。我对此做了很多研究,但我无法成功。有什么方法可以实现吗?

4

1 回答 1

0

您可以通过 title 属性将它们分开。例子:

UIATarget.onAlert = function onAlert(alert) {
    var title = alert.name();

    //check by title, which alert is.

    // test if your script should handle the alert, and if so, return true
    // otherwise, return false to use the default handler
    return false;
}
于 2015-01-30T13:39:52.403 回答