Contributions
Re: iOS 9 Change In Notifications Alert After Uninstall/Reinstall
Found a workaround! After installing the app and launching it, we get the Notification alert. This blocks the rest of the script from running. I noticed yesterday (by accident) that if the app is removed, installed, and launched again through our script with the alert still up, the script works! It just runs in the background behind the alert that is currently displayed. I'm not sure why this happens, but I think we can at least run our tests now without the manual step of allowing notifications. -Corey2.5KViews2likes1CommentRe: iOS 9 Change In Notifications Alert After Uninstall/Reinstall
Hi Alex, thanks for the reply! To clarify, ImageRepository works for us, just not when this alert comes up. We can't select an image on the screen because TestComplete requires the tested app to be running, but it can't see the app in this case. The link you provided is a solution for Appium, not TestComplete. I've actually tried this and you can get around the issue in Appium, but I'm not aware of a way to get around it in TestComplete. Please correct me if I misunderstood or am wrong about something. I appreciate the help! Thanks! Corey2.6KViews0likes0CommentsiOS 9 Change In Notifications Alert After Uninstall/Reinstall
We've had an ongoing problem with iOS system alerts blocking our scripts from running, such as allowing notifications, location services, camera access, etc. Our workaround prior to iOS 9 was to install the app and accept all the prompts manually once, then they wouldn't come up again when the app was uninstalled/reinstalled from our scripts because the settings were remembered on the device. Now with iOS 9, the notification setting is not saved. This means that every time our scripts run, the notification alert comes up and blocks the rest of our tests from running (I attached a screenshot of this alert). I also found this post with more detail about what's happening: https://forums.developer.apple.com/message/50273#50273 Has anyone else run into this and come up with any solutions? We've tried tapping a specific point on the screen, which doesn't work because TestComplete doesn't see the app when these alerts are up. We can't use ImageRepositories for the same reason. We haven't found any properties or settings to set these values or disable the prompts on the device or in TestComplete. One possible solution is to not uninstall the app every time our scripts run, but we really want a clean build every time so we don't keep any bad data around. If we leave it the way it is now, we have to manually tap "OK" to this prompt when it gets to that point in the script, which prevents us from running our tests on a schedule, e.g. every night. Any ideas would be appreciated :) Thanks, CoreySolved2.6KViews0likes4CommentsAbility To Check Network Connection Status On iOS (Wi-Fi Status, Etc.)
We would like the ability to check if there is a network connection on iOS. Sometimes the connection is temporarily lost, and it would be great to be able to check for that before running tests that rely on a network connection. This would save us time and prevent lots of unnecessary failures. Thanks, Corey2.5KViews2likes1CommentRe: Get version of running application?
I think what you are looking for is this: http://support.smartbear.com/viewarticle/74508/ In the example from the link above, you would want to use appObj.BundleVersion. This assumes you are trying to get the version of a known app with a known bundle ID. Also, here is the full list of properties for other info about the app: http://support.smartbear.com/viewarticle/68466/ -Corey1.7KViews2likes1CommentRe: iOS: Performing swipe action on the tablecell.
We've had some issues with this in the past too, but I think we have found a good solution to swipe from right to left in a TableVewCell. An example procedure is below (in DelphiScript). It finds the coordinates by using the cell's position and size, then swipes. Just pass in the TableViewCell object: procedure SwipeToExposeRemoveButton(oTableViewCell : OleVariant); var iScreenTop, iScreenLeft, xStart, yStart, xEnd, yEnd : integer; begin iScreenTop := oTableViewCell.ScreenTop; // Get distance from top of cell to top of screen iScreenLeft := oTableViewCell.ScreenLeft; // Get distance from left of cell to left of screen // Define start and end coordinates to swipe xStart := iScreenLeft + oTableViewCell.Width * 0.99; // Distance left of object + 99/100 the width of cell yStart := oTableViewCell.Height/2 + iScreenTop; // Middle of cell heightwise xEnd := iScreenLeft + oTableViewCell.Width * 0.01; // Distance left of object + 1/100 the width of cell yEnd := yStart; // Swipe to expose remove button Mobile.Device.Swipe(xStart, yStart, xEnd, yEnd, 5, 200); end; Hope this helps! -Corey2.1KViews3likes1Comment