Improve error when using sync time with b2g and no wifi settings file

RESOLVED FIXED

Status

Testing Graveyard
Eideticker
RESOLVED FIXED
4 years ago
6 months ago

People

(Reporter: davehunt, Assigned: davehunt)

Tracking

Details

Attachments

(1 attachment)

(Assignee)

Description

4 years ago
Currently if you're testing B2G with sync time enabled but not WiFi settings file, the test does not fail immediately or with a useful error message:

$ ./bin/runtest.py --device-type=b2g b2g-settings-startup
Using adb interface (type: b2g, host: None, port: None, debuglevel: 20)
DeviceManager INFO | Waiting for Marionette...
DeviceManager INFO | Marionette ready!
2014-01-17 09:27:56,390 Eideticker INFO | Resetting B2G and cleaning up...
2014-01-17 09:27:57,905 Eideticker INFO | Restarting b2g
Testinfo: {'name': 'startup.py', 'appname': 'Settings', 'here': '/Users/dhunt/workspace/eideticker/src/tests/b2g/applaunching', 'manifest': '/Users/dhunt/workspace/eideticker/src/tests/b2g/applaunching/settings-startup.ini', 'expected': 'pass', 'defaultMeasure': 'timetostableframe', 'preInitializeProfile': '0', 'key': 'b2g-settings-startup', 'captureTimeout': '5', 'shortDesc': 'Time to full display of firefoxos browser application', 'path': '/Users/dhunt/workspace/eideticker/src/tests/b2g/applaunching/startup.py', 'type': 'b2g', 'relpath': 'b2g/applaunching/startup.py'}
Using adb interface (type: b2g, host: None, port: None, debuglevel: 20)
DeviceManager INFO | Waiting for Marionette...
DeviceManager INFO | Marionette ready!
Traceback (most recent call last):
  File "./bin/runtest.py", line 72, in <module>
    main()
  File "./bin/runtest.py", line 66, in main
    sync_time=options.sync_time)
  File "/Users/dhunt/workspace/eideticker/src/eideticker/eideticker/runtest.py", line 81, in run_test
    wifi_settings = json.loads(open(wifi_settings_file).read())
TypeError: coercing to Unicode: need string or buffer, NoneType found
(Assignee)

Comment 1

4 years ago
Created attachment 8361570 [details] [diff] [review]
Improve error when using sync time with b2g and no wifi settings file. v1.0
Attachment #8361570 - Flags: review?(wlachance)
Comment on attachment 8361570 [details] [diff] [review]
Improve error when using sync time with b2g and no wifi settings file. v1.0

Review of attachment 8361570 [details] [diff] [review]:
-----------------------------------------------------------------

lgtm
Attachment #8361570 - Flags: review?(wlachance) → review+
Pushed: https://github.com/mozilla/eideticker/commit/ee26cba9180b8350c7434f593572a2cd404d267f
Status: ASSIGNED → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → FIXED

Updated

6 months ago
Product: Testing → Testing Graveyard
You need to log in before you can comment on or make changes to this bug.