| Index: third_party/WebKit/LayoutTests/sensor/resources/generic-sensor-tests.js
|
| diff --git a/third_party/WebKit/LayoutTests/sensor/resources/generic-sensor-tests.js b/third_party/WebKit/LayoutTests/sensor/resources/generic-sensor-tests.js
|
| index 3f671e44035b77752c5dd9dced9f7b97ca735364..b0baa2a077e1b87b5a3ba20556fa5974c54dfb7f 100644
|
| --- a/third_party/WebKit/LayoutTests/sensor/resources/generic-sensor-tests.js
|
| +++ b/third_party/WebKit/LayoutTests/sensor/resources/generic-sensor-tests.js
|
| @@ -97,9 +97,11 @@ function runGenericSensorTests(sensorType, updateReading, verifyReading) {
|
| }, 'Test that frequency is capped to the maximum supported from frequency.');
|
|
|
| sensor_test(sensor => {
|
| - let sensorObject = new sensorType({frequency: 60});
|
| - sensorObject.start();
|
| - let testPromise = sensor.mockSensorProvider.getCreatedSensor()
|
| + let sensorObject = new sensorType({frequency: 60});
|
| + assert_equals(sensorObject.state, 'unconnected');
|
| + sensorObject.start();
|
| + assert_equals(sensorObject.state, 'activating');
|
| + let testPromise = sensor.mockSensorProvider.getCreatedSensor()
|
| .then((mockSensor) => {
|
| return new Promise((resolve, reject) => {
|
| let wrapper = new CallbackWrapper(() => {
|
| @@ -113,8 +115,8 @@ function runGenericSensorTests(sensorType, updateReading, verifyReading) {
|
| });
|
| })
|
| .then(mockSensor => { return mockSensor.removeConfigurationCalled(); });
|
| - return testPromise;
|
| - }, 'Test that sensor can be successfully created if sensor is supported.');
|
| + return testPromise;
|
| + }, 'Test that sensor can be successfully created and its states are correct.');
|
|
|
| sensor_test(sensor => {
|
| let sensorObject = new sensorType();
|
|
|