Closed Bug 980811 Opened 11 years ago Closed 11 years ago

Modify the test_settings_sim_manager.py

Categories

(Firefox OS Graveyard :: Gaia::UI Tests, defect)

All
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: askeing, Unassigned)

Details

Attachments

(2 files)

46 bytes, text/x-github-pull-request
ericcc
: review-
Details | Review
46 bytes, text/x-github-pull-request
zcampbell
: review+
askeing
: review+
Details | Review
The "multi-sim" doesn't work with "type" option, ex: "--type=b2g-mutli-sime".
Have to modify it.

And it seems like we can add a check before tap the SIM Manager memu.
If there is no memu item, then skip the tests.
ref: https://github.com/mozilla-b2g/gaia/blob/master/tests/python/gaia-ui-tests/gaiatest/apps/settings/app.py#L138
Flags: needinfo?(echang)
IMO, this test should be skip by default.
Only if user run with "--type=b2g+multisim" option, then gaiatest will run it.
Any suggestion, Zac?
(In reply to Askeing Yen[:askeing] from comment #1)
> IMO, this test should be skip by default.
> Only if user run with "--type=b2g+multisim" option, then gaiatest will run
> it.
> Any suggestion, Zac?

I think it's safer to run all tests by default, otherwise there's a risk of tests being overlooked. We could also have a skip in the test if the test is selected but the device does not support multiple sims, similar to our email tests [1]. Note that your type cannot contain a hyphen (-) as this is used as a prefix for excluding types.

[1] https://github.com/mozilla-b2g/gaia/blob/b3758a90b8888e9d95128846b2833b4d9444ef7f/tests/python/gaia-ui-tests/gaiatest/tests/functional/email/test_setup_basic_gmail.py#L14
(In reply to Dave Hunt (:davehunt) from comment #2)
> (In reply to Askeing Yen[:askeing] from comment #1)
> > IMO, this test should be skip by default.
> > Only if user run with "--type=b2g+multisim" option, then gaiatest will run
> > it.
> > Any suggestion, Zac?
> 
> I think it's safer to run all tests by default, otherwise there's a risk of
> tests being overlooked. We could also have a skip in the test if the test is
> selected but the device does not support multiple sims, similar to our email
> tests [1]. Note that your type cannot contain a hyphen (-) as this is used
> as a prefix for excluding types.
> 
> [1]
> https://github.com/mozilla-b2g/gaia/blob/
> b3758a90b8888e9d95128846b2833b4d9444ef7f/tests/python/gaia-ui-tests/gaiatest/
> tests/functional/email/test_setup_basic_gmail.py#L14

agree :)
Then I'll suggest add a check before try to tap the SIM Manager memu item.
(In reply to Askeing Yen[:askeing] from comment #3)
> (In reply to Dave Hunt (:davehunt) from comment #2)
> > (In reply to Askeing Yen[:askeing] from comment #1)
> Then I'll suggest add a check before try to tap the SIM Manager memu item.

Is it not possible to detect this via a WebAPI?
We could just remove multisim altogether.

run-if = device == "taroko" (replacing taroko with whatever the code is)

however it would mean you have to always be running the dual sim device with two sims but other solutions noted here make this assumption too.
Attached file github pr
Attachment #8387682 - Flags: review?(fyen)
Attachment #8387682 - Flags: review?(echang)
Thanks a lot, I checked on the Fugu, the device ID is "sp7710gaplus_gonk", I will submit another PR.
run-if = device == "sp7710gaplus_gonk"
Flags: needinfo?(echang)
Attachment #8387682 - Flags: review?(echang) → review-
Attachment #8388346 - Flags: review?(zcampbell)
Attachment #8388346 - Flags: review?(fyen)
Comment on attachment 8388346 [details] [review]
PR 17012 change Fugu device ID

I don't have fugu device.
But we can check the 'device' by 'adb shell getprop | grep ro.product.device'.
r+ if the device name works correctly.
Attachment #8388346 - Flags: review?(fyen) → review+
(In reply to Eric Chang [:ericcc] [:echang] from comment #7)
> Thanks a lot, I checked on the Fugu, the device ID is "sp7710gaplus_gonk", I
> will submit another PR.
> run-if = device == "sp7710gaplus_gonk"

Thanks for checking that for us!
Comment on attachment 8388346 [details] [review]
PR 17012 change Fugu device ID

r+
Attachment #8388346 - Flags: review?(zcampbell) → review+
Merged:
https://github.com/mozilla-b2g/gaia/commit/11b44326c3a9a513c3d930ac7c1afac52d7c8b52
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
(In reply to Dave Hunt (:davehunt) from comment #4)
> (In reply to Askeing Yen[:askeing] from comment #3)
> > (In reply to Dave Hunt (:davehunt) from comment #2)
> > > (In reply to Askeing Yen[:askeing] from comment #1)
> > Then I'll suggest add a check before try to tap the SIM Manager memu item.
> 
> Is it not possible to detect this via a WebAPI?
Good idea, I checked that on https://wiki.mozilla.org/WebAPI/WebIccManager/Multi-SIM
navigator.mozMobileConnections[0] we can check the length of this array to see the number of the slots of a device, I tried that on one of my packaged app. And navigator.mozIccManager.iccIds.length, this is the number of sims inserted.
Attachment #8387682 - Flags: review?(fyen)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: