edge/pkg/module/cast/testdata/cast.js

22 lines
429 B
JavaScript
Raw Normal View History

2023-02-17 10:38:45 +01:00
cast.refreshDevices('5s')
.then(function(devices) {
console.log(devices)
if (devices === null) {
throw new Error("devices should not be null");
}
if (devices.length === 0) {
throw new Error("devices.length should not be 0");
}
return devices
})
.then(function(devices) {
return cast.getStatus(devices[0].uuid)
})
.then(function(status) {
console.log(status)
})