blob: a7c4b35ec6c53ca0851667f6b28ccf085155111d [file] [log] [blame]
Test battery status API with multiple promises after resolve.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
resolution number 1
PASS batteryInfo is defined.
PASS lastSetMockBatteryInfo is defined.
PASS batteryInfo.charging is lastSetMockBatteryInfo.charging
PASS batteryInfo.chargingTime is lastSetMockBatteryInfo.chargingTime
PASS batteryInfo.dischargingTime is lastSetMockBatteryInfo.dischargingTime
PASS batteryInfo.level is lastSetMockBatteryInfo.level
PASS promise1 === promise2 is true
resolution number 2
PASS batteryInfo is defined.
PASS lastSetMockBatteryInfo is defined.
PASS batteryInfo.charging is lastSetMockBatteryInfo.charging
PASS batteryInfo.chargingTime is lastSetMockBatteryInfo.chargingTime
PASS batteryInfo.dischargingTime is lastSetMockBatteryInfo.dischargingTime
PASS batteryInfo.level is lastSetMockBatteryInfo.level
PASS successfullyParsed is true
TEST COMPLETE