TestRigor calling feature test - testrigor

Iam trying to test calling feature using testrigor and twilio
Below is my one line test :
call "+91797401288x" from "+9183196902x4" and verify it is ringing
What I did I put 91797401288x on airplane mode to check test fails or not and test got passed,looks like there is some issue with tool ?? or am I doing wrong

You did everything correctly. I was able to duplicate your issue and I created an issue ticket. I will update here when I get a response from support.

Sumit. The issue is that when testRigor calls, it can only perform the validation from the side that it is connected, which is the caller. If a phone is on airplane mode, from the caller's perspective, the phone may ring. The holder of the phone may not hear the ringing, but the ringback tone may still be sent to the caller depending on how the service provider and the particular phone communicate. Airplane mode is to prevent the phone's holder from being disturbed, but not to notify callers. You can test this by telling a friend of yours to turn their phone on airplane mode. You may need to try more than one friend or have your friend do the same to you. If you're calling, you may hear the ringback tone, but your friend would not hear the ringtone. That's what's happening on testRigor. From testRigor's perspective, it is ringing. The phone service provider would have to intervene in some way to notify the caller that the person they are calling is not available. Otherwise, testRigor has no way of knowing that the phone is on airplane mode.
-This answer is from direct feedback from testRigor engineers.

Related

Network reachability notification on status change is mandatory on iPhone?

Many reachability test codes seem to incorporate "notify" concept so that when network gets back on, user can get notified.
Do I need to implement the "notification" part? Is it acceptable to alert user whenever he tries something that needs network connection and it is not available? (without notification when connection gets back)
I see example codes deals with pure network availability(if the device is connected to wifi, 3g, and so on) and with reachability to specific ip. My app needs to connect to specific ip address when appropriate. In this scenario, just alerting if that ip is not reachable in appropriate times are all that's required or do I need to handle something more?(such as putting different messages for alerting user to turn on network and for alerting user that my ip is not reachable)
Thank you
1.
I'd recommend taking a look at Andrew Donoho's Reachability class that is an extension of the sample released by Apple:
http://blog.ddg.com/?p=24
That'll abstract away the need to worry about handling the notifications and allow you to focus on simply testing the reachability of your IP or if a certain network type is active.
2.
In terms to actual notification to the user, I'd say that depends on your application. For instance on the vast majority of the screens on one of my Apps the UIView attempts to do an async download of data from a RESTful service when that view loads. I don't do any reachability tests beforehand, I simply attempt to make the call and if the request fails, I notify the user after the fact. Unless you have a specific case of needing to know an IP is reachable, I'd think in the general case handling any errors on connections attempts should be sufficient. I'm sure there are are plenty of edge cases though that you might want to test reachability first.
On the other hand I do use the reachability on a given screen that I recommend a WiFi connection. Since that screen performs a fairly data intensive sync, I warn the user if they are on 3G that the sync make take quite a bit longer vs. WiFi simply performs the sync.
AFAIK, there is no requirement that you pop up a notification when the network becomes available, or in fact that you actually pop up a notification when the network is not available. You could instead enable/disable network-related buttons (as long as the user can know why the buttons are disabled), display an unobtrusive on-screen indicator, or whatever.
The important part is that you do not display a blank screen or a cryptic error message when the network is not available, or otherwise leave the user wondering why things aren't working.
I don't know of any requirement that you differentiate between "networking off" and "networking on but IP address unreachable".

iPhone reachability test needed everytime a connection is to be made?

I have a app from where i hit different REST urls. one of the service is login service.
Now, do i have to use the apple rechability test everytime i want to make a connection?
I use ASIHttpRequest
No, ASIHTTPRequest will return a timeout error / a connection failure error if it can't reach the host. You can use those errors to show something to the user to tell them their login has failed.
The connectivity status of your mobile device can change very often and unforeseeably, so checking it often is advisable.
Say, for example, that you check at app startup, and find that not network is available. You go to offline mode, but then in a few minutes you could get in a WI-FI area or your 3G signal might be stronger. If you don't check it again, you lose the possibility of going to online mode.
Indeed, checking for network availability is pretty fast compared to how long a network request lasts (say: sending a login request and waiting for the response), so you can safely do the check whenever you need it according to your policy, be it at each request, every 5 minutes, or whatever.
EDIT:
about your concern as to the approval process: you should ensure that your app has a reasonable behavior when no connection it available. Simply showing an alert to the user (and not crashing) is enough for Apple, but you could also resort to disabling all your network related buttons, or whatever fits your app. The idea is that your app should not behave crazily when no connection is available.
If you want more advanced behavior, you can check reachability with each request.
You can also use the Reachability notification service (ASIHTTP-bundled Reachability includes that feature). You can find an how-to here. But in my opinion is a bit easier to just do the check when you need it. YMMV
From what I remember the reachability demo code is effectively a listener so can update a variable as the device's reachability state changes. You then need to check this variable before making a request.
Would be surprised ASIHTTP doesn't do this kind of thing already.

Question regarding iphone allowance of custom notifications

I have an app that I am working on, and part of its main functionality is to alert the user to do something. So even though they aren't in the app, I want to be able to pop up an alert from the app, reminding them to do something. Is that allowed with the iPhone sdk? Maybe it isn't even a big deal at all, but for some reason I was thinking that it would require background processes or something that may or may not be possible. Anyone who has any thoughts about how this would be implemented would be greatly appreciated. Thanks!
Check out the Apple documentation on push notifications. Short of jailbreaking and distributing your app outside the App Store, there is no way to run background processes at this time.
It is allowed through notifications, though you will need a server to actually send the notifications to the user. There is no limit to the number you can send, although the user may very well decide to shut off notifications or delete your app altogether if you are too spastic with them. Make very sure the user understands the notification volume they will receive and agrees to it...
The way the system works is the user gets a notification message (and/or sound) and can decide to open your app or not, as the time of notification.

Can an iPhone App take exclusive control or reliably record why it lost control

I am trying to determine feasibility of certain features required in a (potential) project. I am not (yet) looking for a how-to, just a can-do. I apologize for any vagueness and ignorance: the former due to an NDA that makes Apple's NDA look like GPL, and the latter due to the fact that I have no iPhone or MAC experience.
I do have a solid understanding of objective-c and interface builder (going back to NextStep) and some PDA development experience, so I'll probably understand the answers, even if my questions are naive. I have done a bit of browsing, so I know some buzzwords.
I can't go into detail about the actual project, but I have come up with a lame analogy.
a large number of users in the same room are asked to complete task(s) in the app (say a puzzle)
they are under supervision, but the monitor cannot watch them all closely
they are not allowed to leave the application until done.
they cannot send/receive phone calls or messages during the task.
the monitor receives notification of various steps during the task
the monitor is notified when the task is completed, or the app is exited
the app sends a heartbeat, so the monitor also knows if signal is lost
Jailbreak is not an option.
The app should also work on iPod Touch.
So the things I need to do that seem dicey to me are
can I turn off (or require the user to turn off) phone and sms but still be able send http to my server
can I prevent an app from being switched out (even if, say an alarm app triggers or the phone rings).
failing prevention, can I at least detect any of these events and notify my server.
failing notification, can I record the event for the monitor to check later.
The user will be aware (and in fact welcome) these restrictions. It's a trust issue - the user must not seek help or use a helper app to solve the puzzle, and wants the monitor (and other contestants) to know that he did not. It's feasible for the user to click on an "OK, I understand and approve" screen at the beginning, but not for each communication to the server.
The app would only communicate with a central server (run by my company) - the monitor would not be able to buy the server software, and the url's of the server would not be user (or monitor) modifiable.
Hey! This looks like an app for taking exams. Not what I am doing, but that would be cool too!
EDIT --
I changed the title and am adding a few more parts to the question, based in part on mmc's answer. The App may run in an offline mode that would have to do the following:
So using the exam analogy, the user off line experience would be something like this
Launch App
App download test questions, registers start time, etc.
Turn off phone (if app can't do it by itself)
Disable any app that might interrupt my App (can app do this?)
Resume and Take Test
Indicate test done (or finish last problem).
Turn on phone (if app can't) and restart App (if needed).
App uploads test results and log of any interruptions.
So the question becomes
Am I sure that I at least get to log any interruption I can't prevent
can I know the cause of the interruption (phone answered, alarm launch, user initiated)?
can the user be prevented from modifying the log
can I know what other Apps are running when I start? (to guard against a daemon that occasionally displays a hint or something.
I would still like to run with real time uploads, so a few other ideas come to mind.
If I can reliably detect and record that the phone or another app was used, that might be almost as good as preventing it.
Can the user prevent the phone from ringing even if it's on (eg. call forward + ringer off)
Can my app know if the ringer is off
Same question for sms messaging
If I can't block it, can the user just ignore (silent) call or message and not leave my App. Would my app know that?
Sounds like you might be better off doing away with the phone, and making it exclusive to the iPod Touch.
You've nailed your trouble spots.
There is no way to disable phone functionality, and at the same time maintain network functionality of any type (3G, WiFi, or bluetooth) If you disable the phone operations with Airplane mode, all of them are disabled.
There is no way to prevent the Home button from returning you to Springboard
You can notify a server of a premature app interruption (there is an applicationWillTerminate: method on your app delegate) but is not reliable. If the operation takes too long, your app will be forcibly terminated.
You could write to the local file system that a premature interruption happened, and this would be far more reliable, as this operation would be much faster.

Logging calls after hanging up on smart phones

In the various smartphone APIs/SDKs, I was wondering if it is possible to prompt a user if they'd like to log a phone call after they hang up. The most basic functionality would be after calling out or receiving a call, the phone would ask
Do you want to log the call to|from 555-555-5555?
Yes | No | Never this number
(then it might take the user to a small form and then post the info to a webservice)
The business use is for lawyers who have company phones and need to track billing.
this is a bit different question than Accessing the iPhone's Call log with the iPhone SDK.
On an Android phone you can register a PhoneStateListener to receive a notification of when a call hangs up and log the number by whatever method you wish.
Blackberries have call logging out of the box. Blackberry Enterprise Server activated units sync the log with the server.
On iPhone, no way.
Apple would have to allow (shudder) background applications.
Note: Shraptnel is right, you may be able to monitor the phone state with some private API's if you jailbroke your phone and ran your program in the background.