Hi Everyone,
I am trying to test telephony using mock_ril. After mock_ril bring-up,
while I start to run TelephonyMockRilTest, it crashing due to time
consuming Telephony test cases are runing on activity main thread.
After analysis, I moved the time consuming socket operation function into a
new thread to fix the exception.
Below is file and code changes:
File path:
frameworks\base\telephony\tests\telephonytests\src\com\android\frameworks\telephonytests\
TelephonyMockRilTestRunner.java
@Override
public void onCreate(Bundle icicle) {
log("onCreate E");
new Thread( new Runnable() {
public void run() {
try {
mMockRilChannel = RilChannel.makeRilChannel();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
} ).start();
log("onCreate X");
super.onCreate(icicle);
}
Now it works perfectly, I request you to comment on this. Is this solution
ok?
Thanks and regards,
Suchand
--
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
---
You received this message because you are subscribed to the Google Groups
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.