mirror of
https://github.com/skydiver/ewelink-api.git
synced 2025-12-24 14:31:53 +01:00
Release v1.4.0 (#11)
* refactor websocket / power usage * cooldown between api requests during testing * refactor power state methods * remove unused code * cooldown between api requests during testing * version bump
This commit is contained in:
@@ -10,6 +10,10 @@ const {
|
||||
const { loginExpectations } = require('./_setup/expectations');
|
||||
|
||||
describe('valid credentials, invalid device', () => {
|
||||
beforeEach(async () => {
|
||||
await delay(1000);
|
||||
});
|
||||
|
||||
test('get device power state should fail', async () => {
|
||||
const conn = new ewelink({ email, password });
|
||||
const powerState = await conn.getDevicePowerState('invalid deviceid');
|
||||
@@ -54,7 +58,6 @@ describe('valid credentials, invalid device', () => {
|
||||
|
||||
test('raw power on device without electricity monitor should fail', async () => {
|
||||
jest.setTimeout(30000);
|
||||
await delay(1000);
|
||||
const conn = new ewelink({ email, password });
|
||||
const powerUsage = await conn.getDeviceRawPowerUsage(deviceIdWithoutPower);
|
||||
expect(typeof powerUsage).toBe('object');
|
||||
|
||||
Reference in New Issue
Block a user