@sebbo2002/node-pyatv 6.0.0-develop.1 → 6.0.0-develop.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/lib/device.d.ts +12 -1
  3. package/dist/lib/device.js +37 -0
  4. package/dist/lib/device.js.map +1 -1
  5. package/dist/lib/types.d.ts +5 -0
  6. package/docs/coverage/cobertura-coverage.xml +709 -649
  7. package/docs/coverage/device-event.ts.html +1 -1
  8. package/docs/coverage/device-events.ts.html +8 -8
  9. package/docs/coverage/device.ts.html +138 -21
  10. package/docs/coverage/fake-spawn.ts.html +40 -40
  11. package/docs/coverage/index.html +20 -20
  12. package/docs/coverage/index.ts.html +1 -1
  13. package/docs/coverage/instance.ts.html +1 -1
  14. package/docs/coverage/tools.ts.html +250 -250
  15. package/docs/coverage/types.ts.html +22 -4
  16. package/docs/reference/assets/main.js +1 -1
  17. package/docs/reference/assets/search.js +1 -1
  18. package/docs/reference/classes/NodePyATVDevice.html +112 -74
  19. package/docs/reference/classes/NodePyATVDeviceEvent.html +10 -10
  20. package/docs/reference/classes/NodePyATVInstance.html +14 -14
  21. package/docs/reference/enums/NodePyATVDeviceState.html +11 -11
  22. package/docs/reference/enums/NodePyATVExecutableType.html +7 -7
  23. package/docs/reference/enums/NodePyATVKeys.html +28 -28
  24. package/docs/reference/enums/NodePyATVListenerState.html +9 -9
  25. package/docs/reference/enums/NodePyATVMediaType.html +9 -9
  26. package/docs/reference/enums/NodePyATVPowerState.html +7 -7
  27. package/docs/reference/enums/NodePyATVProtocol.html +9 -9
  28. package/docs/reference/enums/NodePyATVRepeatState.html +8 -8
  29. package/docs/reference/enums/NodePyATVShuffleState.html +8 -8
  30. package/docs/reference/index.html +4 -4
  31. package/docs/reference/interfaces/NodePyATVDeviceOptions.html +25 -25
  32. package/docs/reference/interfaces/NodePyATVFindAndInstanceOptions.html +19 -19
  33. package/docs/reference/interfaces/NodePyATVFindOptions.html +14 -14
  34. package/docs/reference/interfaces/NodePyATVGetStateOptions.html +6 -6
  35. package/docs/reference/interfaces/NodePyATVInstanceOptions.html +10 -10
  36. package/docs/reference/interfaces/NodePyATVService.html +7 -7
  37. package/docs/reference/interfaces/NodePyATVState.html +20 -20
  38. package/docs/reference/interfaces/NodePyATVVersionResponse.html +7 -7
  39. package/docs/reference/modules.html +4 -4
  40. package/docs/reference/types/NodePyATVEventValueType.html +5 -5
  41. package/docs/tests/index.html +1 -1
  42. package/docs/tests/mochawesome.json +705 -627
  43. package/package.json +9 -9
  44. package/src/lib/device.ts +40 -1
  45. package/src/lib/types.ts +6 -0
  46. package/test/device.ts +42 -0
@@ -1,16 +1,16 @@
1
1
  {
2
2
  "stats": {
3
- "suites": 89,
4
- "tests": 153,
5
- "passes": 151,
3
+ "suites": 91,
4
+ "tests": 155,
5
+ "passes": 153,
6
6
  "pending": 2,
7
7
  "failures": 0,
8
- "start": "2023-02-12T20:21:40.021Z",
9
- "end": "2023-02-12T20:21:52.019Z",
10
- "duration": 11998,
11
- "testsRegistered": 153,
8
+ "start": "2023-03-21T19:06:00.060Z",
9
+ "end": "2023-03-21T19:06:12.267Z",
10
+ "duration": 12207,
11
+ "testsRegistered": 155,
12
12
  "passPercent": 100,
13
- "pendingPercent": 1.3071895424836601,
13
+ "pendingPercent": 1.2903225806451613,
14
14
  "other": 0,
15
15
  "hasOther": false,
16
16
  "skipped": 0,
@@ -18,7 +18,7 @@
18
18
  },
19
19
  "results": [
20
20
  {
21
- "uuid": "cd8f1f12-3d15-4c00-821d-051fc67899b0",
21
+ "uuid": "cb2b6f57-83a4-4a9e-9840-6cf9b7c8fe18",
22
22
  "title": "",
23
23
  "fullFile": "",
24
24
  "file": "",
@@ -27,7 +27,7 @@
27
27
  "tests": [],
28
28
  "suites": [
29
29
  {
30
- "uuid": "395e4cf2-a8b6-4aa3-8acc-4734a224da51",
30
+ "uuid": "dcbd2838-ae0b-4830-95bc-6a1da052278d",
31
31
  "title": "NodePyATVDeviceEvent",
32
32
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-event.ts",
33
33
  "file": "/test/device-event.ts",
@@ -36,7 +36,7 @@
36
36
  "tests": [],
37
37
  "suites": [
38
38
  {
39
- "uuid": "301b1330-4223-491c-b896-827053909a03",
39
+ "uuid": "a42c2a01-f377-4f29-a8d7-f15915d4a251",
40
40
  "title": "get key()",
41
41
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-event.ts",
42
42
  "file": "/test/device-event.ts",
@@ -56,15 +56,15 @@
56
56
  "context": null,
57
57
  "code": "const event = new NodePyATVDeviceEvent({\n key: 'genre',\n old: 'Jazz',\n new: 'Rock',\n device: new NodePyATVDevice({\n host: '192.168.178.2',\n name: 'My Testinstance'\n })\n});\nassert.strictEqual(event.key, 'genre');",
58
58
  "err": {},
59
- "uuid": "c3b639e4-0e45-4193-9ec8-416e62a70f6d",
60
- "parentUUID": "301b1330-4223-491c-b896-827053909a03",
59
+ "uuid": "1e1fd9e4-d80b-49cb-88b7-3b337a2102f3",
60
+ "parentUUID": "a42c2a01-f377-4f29-a8d7-f15915d4a251",
61
61
  "isHook": false,
62
62
  "skipped": false
63
63
  }
64
64
  ],
65
65
  "suites": [],
66
66
  "passes": [
67
- "c3b639e4-0e45-4193-9ec8-416e62a70f6d"
67
+ "1e1fd9e4-d80b-49cb-88b7-3b337a2102f3"
68
68
  ],
69
69
  "failures": [],
70
70
  "pending": [],
@@ -75,7 +75,7 @@
75
75
  "_timeout": 2000
76
76
  },
77
77
  {
78
- "uuid": "ed8d902a-4583-4048-8525-d3c6aa7ec769",
78
+ "uuid": "afdd5f23-3688-4828-8572-99442f96e04d",
79
79
  "title": "get oldValue()",
80
80
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-event.ts",
81
81
  "file": "/test/device-event.ts",
@@ -95,15 +95,15 @@
95
95
  "context": null,
96
96
  "code": "const event = new NodePyATVDeviceEvent({\n key: 'genre',\n old: 'Jazz',\n new: 'Rock',\n device: new NodePyATVDevice({\n host: '192.168.178.2',\n name: 'My Testinstance'\n })\n});\nassert.strictEqual(event.oldValue, 'Jazz');",
97
97
  "err": {},
98
- "uuid": "12ac40a7-bf7c-4cf9-b121-39b72ef19d05",
99
- "parentUUID": "ed8d902a-4583-4048-8525-d3c6aa7ec769",
98
+ "uuid": "d84cfc45-8fed-48c7-8367-ecaf8f994eb1",
99
+ "parentUUID": "afdd5f23-3688-4828-8572-99442f96e04d",
100
100
  "isHook": false,
101
101
  "skipped": false
102
102
  }
103
103
  ],
104
104
  "suites": [],
105
105
  "passes": [
106
- "12ac40a7-bf7c-4cf9-b121-39b72ef19d05"
106
+ "d84cfc45-8fed-48c7-8367-ecaf8f994eb1"
107
107
  ],
108
108
  "failures": [],
109
109
  "pending": [],
@@ -114,7 +114,7 @@
114
114
  "_timeout": 2000
115
115
  },
116
116
  {
117
- "uuid": "c87156be-8f1b-4c1c-9711-c71fb271277d",
117
+ "uuid": "a1f366b9-d57e-4bbf-a166-cfdf70fac381",
118
118
  "title": "get newValue()",
119
119
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-event.ts",
120
120
  "file": "/test/device-event.ts",
@@ -134,15 +134,15 @@
134
134
  "context": null,
135
135
  "code": "const event = new NodePyATVDeviceEvent({\n key: 'genre',\n old: 'Jazz',\n new: 'Rock',\n device: new NodePyATVDevice({\n host: '192.168.178.2',\n name: 'My Testinstance'\n })\n});\nassert.strictEqual(event.newValue, 'Rock');",
136
136
  "err": {},
137
- "uuid": "737b0713-54fd-4674-92e2-c3a286e295c4",
138
- "parentUUID": "c87156be-8f1b-4c1c-9711-c71fb271277d",
137
+ "uuid": "dc78a171-e1f1-49eb-a3f0-eccdc8f0d164",
138
+ "parentUUID": "a1f366b9-d57e-4bbf-a166-cfdf70fac381",
139
139
  "isHook": false,
140
140
  "skipped": false
141
141
  }
142
142
  ],
143
143
  "suites": [],
144
144
  "passes": [
145
- "737b0713-54fd-4674-92e2-c3a286e295c4"
145
+ "dc78a171-e1f1-49eb-a3f0-eccdc8f0d164"
146
146
  ],
147
147
  "failures": [],
148
148
  "pending": [],
@@ -153,7 +153,7 @@
153
153
  "_timeout": 2000
154
154
  },
155
155
  {
156
- "uuid": "722ba932-da1b-4dea-aa64-dd39d8e7f263",
156
+ "uuid": "34499f4f-8a0a-472a-9816-c8edaef6642b",
157
157
  "title": "get value()",
158
158
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-event.ts",
159
159
  "file": "/test/device-event.ts",
@@ -173,15 +173,15 @@
173
173
  "context": null,
174
174
  "code": "const event = new NodePyATVDeviceEvent({\n key: 'genre',\n old: 'Jazz',\n new: 'Rock',\n device: new NodePyATVDevice({\n host: '192.168.178.2',\n name: 'My Testinstance'\n })\n});\nassert.strictEqual(event.value, 'Rock');",
175
175
  "err": {},
176
- "uuid": "086894bb-c10c-402f-bb9a-22e3685b9183",
177
- "parentUUID": "722ba932-da1b-4dea-aa64-dd39d8e7f263",
176
+ "uuid": "efd6a4a7-2d84-46f6-865b-918ce3148d27",
177
+ "parentUUID": "34499f4f-8a0a-472a-9816-c8edaef6642b",
178
178
  "isHook": false,
179
179
  "skipped": false
180
180
  }
181
181
  ],
182
182
  "suites": [],
183
183
  "passes": [
184
- "086894bb-c10c-402f-bb9a-22e3685b9183"
184
+ "efd6a4a7-2d84-46f6-865b-918ce3148d27"
185
185
  ],
186
186
  "failures": [],
187
187
  "pending": [],
@@ -192,7 +192,7 @@
192
192
  "_timeout": 2000
193
193
  },
194
194
  {
195
- "uuid": "75d4bd9c-23bc-4f5e-b1dd-5dc81b709799",
195
+ "uuid": "b638c1ee-f054-41e5-ae7f-1e444cf9d96d",
196
196
  "title": "get device()",
197
197
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-event.ts",
198
198
  "file": "/test/device-event.ts",
@@ -212,15 +212,15 @@
212
212
  "context": null,
213
213
  "code": "const device = new NodePyATVDevice({\n host: '192.168.178.2',\n name: 'My Testinstance'\n});\nconst event = new NodePyATVDeviceEvent({\n key: 'genre',\n old: 'Jazz',\n new: 'Rock',\n device\n});\nassert.deepEqual(event.device, device);",
214
214
  "err": {},
215
- "uuid": "8f328fb3-529f-41e9-b212-0f90bad6a299",
216
- "parentUUID": "75d4bd9c-23bc-4f5e-b1dd-5dc81b709799",
215
+ "uuid": "471cd8d5-64ad-4e08-ba94-1ddc83890dab",
216
+ "parentUUID": "b638c1ee-f054-41e5-ae7f-1e444cf9d96d",
217
217
  "isHook": false,
218
218
  "skipped": false
219
219
  }
220
220
  ],
221
221
  "suites": [],
222
222
  "passes": [
223
- "8f328fb3-529f-41e9-b212-0f90bad6a299"
223
+ "471cd8d5-64ad-4e08-ba94-1ddc83890dab"
224
224
  ],
225
225
  "failures": [],
226
226
  "pending": [],
@@ -241,7 +241,7 @@
241
241
  "_timeout": 2000
242
242
  },
243
243
  {
244
- "uuid": "acfc4651-bd0a-4866-bde3-1c6d91ff4ad8",
244
+ "uuid": "80bd38b8-09f6-4b7c-9f78-394eeb41751d",
245
245
  "title": "NodePyATVDeviceEvents",
246
246
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
247
247
  "file": "/test/device-events.ts",
@@ -250,7 +250,7 @@
250
250
  "tests": [],
251
251
  "suites": [
252
252
  {
253
- "uuid": "c9a870f1-d531-43c7-b775-bd09487db80e",
253
+ "uuid": "7ae68349-5f8b-4dea-92b9-003a68d63456",
254
254
  "title": "applyStateAndEmitEvents()",
255
255
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
256
256
  "file": "/test/device-events.ts",
@@ -270,8 +270,8 @@
270
270
  "context": null,
271
271
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n })\n });\n yield new Promise(cb => {\n device.once('update:title', event => {\n assert.ok(event instanceof NodePyATVDeviceEvent);\n assert.strictEqual(event.key, 'title');\n assert.strictEqual(event.oldValue, null);\n assert.strictEqual(event.newValue, 'My Movie');\n assert.strictEqual(event.value, 'My Movie');\n assert.deepStrictEqual(event.device, device);\n cb(undefined);\n });\n });\n});",
272
272
  "err": {},
273
- "uuid": "4d0f5ece-7b86-447a-a2f9-41788f9bdb99",
274
- "parentUUID": "c9a870f1-d531-43c7-b775-bd09487db80e",
273
+ "uuid": "678e78f0-675b-4077-a1ca-fcf563573080",
274
+ "parentUUID": "7ae68349-5f8b-4dea-92b9-003a68d63456",
275
275
  "isHook": false,
276
276
  "skipped": false
277
277
  },
@@ -279,7 +279,7 @@
279
279
  "title": "should emit update event",
280
280
  "fullTitle": "NodePyATVDeviceEvents applyStateAndEmitEvents() should emit update event",
281
281
  "timedOut": false,
282
- "duration": 2,
282
+ "duration": 6,
283
283
  "state": "passed",
284
284
  "speed": "fast",
285
285
  "pass": true,
@@ -288,8 +288,8 @@
288
288
  "context": null,
289
289
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n })\n });\n yield new Promise(cb => {\n device.once('update', event => {\n assert.ok(event instanceof NodePyATVDeviceEvent);\n assert.strictEqual(event.key, 'title');\n assert.strictEqual(event.oldValue, null);\n assert.strictEqual(event.newValue, 'My Movie');\n assert.strictEqual(event.value, 'My Movie');\n assert.deepStrictEqual(event.device, device);\n cb(undefined);\n });\n });\n});",
290
290
  "err": {},
291
- "uuid": "2fd45f5f-cc18-44ab-9e8a-4f7d55627ca7",
292
- "parentUUID": "c9a870f1-d531-43c7-b775-bd09487db80e",
291
+ "uuid": "2ffa0f11-97f3-47cb-9208-8dbb115481de",
292
+ "parentUUID": "7ae68349-5f8b-4dea-92b9-003a68d63456",
293
293
  "isHook": false,
294
294
  "skipped": false
295
295
  },
@@ -306,8 +306,8 @@
306
306
  "context": null,
307
307
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n })\n });\n const sort = [];\n yield Promise.race([\n new Promise(cb => {\n device.once('update', () => {\n sort.push('update');\n cb(undefined);\n });\n }),\n new Promise(cb => {\n device.once('update:title', () => {\n sort.push('update:title');\n cb(undefined);\n });\n })\n ]);\n assert.deepStrictEqual(sort, ['update:title', 'update']);\n});",
308
308
  "err": {},
309
- "uuid": "e18dd8c5-19e9-4165-87a2-139b1e1db475",
310
- "parentUUID": "c9a870f1-d531-43c7-b775-bd09487db80e",
309
+ "uuid": "a12dff7e-cdea-4f54-a170-53b1a81d23bc",
310
+ "parentUUID": "7ae68349-5f8b-4dea-92b9-003a68d63456",
311
311
  "isHook": false,
312
312
  "skipped": false
313
313
  },
@@ -324,8 +324,8 @@
324
324
  "context": null,
325
325
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'failure',\n datetime: '2021-11-24T21:13:36.424576+03:00',\n exception: 'invalid credentials: 321',\n stacktrace: 'Traceback (most recent call last):\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/scripts/atvscript.py\\\", line 302, in appstart\\n print(args.output(await _handle_command(args, abort_sem, loop)), flush=True)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/scripts/atvscript.py\\\", line 196, in _handle_command\\n atv = await connect(config, loop, protocol=Protocol.MRP)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/__init__.py\\\", line 96, in connect\\n for setup_data in proto_methods.setup(\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/protocols/airplay/__init__.py\\\", line 192, in setup\\n stream = AirPlayStream(config, service)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/protocols/airplay/__init__.py\\\", line 79, in __init__\\n self._credentials: HapCredentials = parse_credentials(self.service.credentials)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/auth/hap_pairing.py\\\", line 139, in parse_credentials\\n raise exceptions.InvalidCredentialsError(\\\"invalid credentials: \\\" + detail_string)\\npyatv.exceptions.InvalidCredentialsError: invalid credentials: 321\\n'\n });\n })\n });\n yield new Promise(cb => {\n device.once('error', error => {\n assert.ok(error instanceof Error);\n assert.ok(error.toString().includes('invalid credentials: 321'));\n cb(undefined);\n });\n });\n});",
326
326
  "err": {},
327
- "uuid": "6ffcd02f-fc7e-4cea-8bad-25c22058973e",
328
- "parentUUID": "c9a870f1-d531-43c7-b775-bd09487db80e",
327
+ "uuid": "b6fce4a7-de6a-4a1b-91d8-c693dca446f1",
328
+ "parentUUID": "7ae68349-5f8b-4dea-92b9-003a68d63456",
329
329
  "isHook": false,
330
330
  "skipped": false
331
331
  },
@@ -333,7 +333,7 @@
333
333
  "title": "should not emit an update if new value is same as old one",
334
334
  "fullTitle": "NodePyATVDeviceEvents applyStateAndEmitEvents() should not emit an update if new value is same as old one",
335
335
  "timedOut": false,
336
- "duration": 4,
336
+ "duration": 3,
337
337
  "state": "passed",
338
338
  "speed": "fast",
339
339
  "pass": true,
@@ -342,8 +342,8 @@
342
342
  "context": null,
343
343
  "code": "return __awaiter(this, void 0, void 0, function* () {\n let spawnCounter = 0;\n let eventCounter = 0;\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n if (spawnCounter === 0) {\n cp.onStdIn(() => cp.end());\n }\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n spawnCounter++;\n if (spawnCounter >= 2) {\n cp.end();\n }\n })\n });\n const listener = () => {\n eventCounter++;\n };\n device.on('update', listener);\n yield new Promise(cb => setTimeout(cb, 0));\n yield device.getState();\n device.off('update', listener);\n assert.strictEqual(spawnCounter, 2);\n assert.strictEqual(eventCounter, 1);\n});",
344
344
  "err": {},
345
- "uuid": "dde29b21-aecb-489f-a114-86cea04781b1",
346
- "parentUUID": "c9a870f1-d531-43c7-b775-bd09487db80e",
345
+ "uuid": "8eafbafb-b2dc-44d8-9440-d92ad56d34a8",
346
+ "parentUUID": "7ae68349-5f8b-4dea-92b9-003a68d63456",
347
347
  "isHook": false,
348
348
  "skipped": false
349
349
  },
@@ -360,8 +360,8 @@
360
360
  "context": null,
361
361
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n })\n });\n let callCounter = 0;\n const error = new Error('This is an error. Be nice.');\n device.once('error', err => {\n assert.strictEqual(err, error);\n callCounter++;\n });\n const listener = () => {\n throw error;\n };\n device.on('update', listener);\n yield new Promise(cb => setTimeout(cb, 0));\n device.off('update', listener);\n assert.strictEqual(callCounter, 1);\n});",
362
362
  "err": {},
363
- "uuid": "fd3c3c76-58cf-4c0f-b69a-03aa8f9bf46a",
364
- "parentUUID": "c9a870f1-d531-43c7-b775-bd09487db80e",
363
+ "uuid": "52e6a084-db78-4ac7-bd3e-a65dde636276",
364
+ "parentUUID": "7ae68349-5f8b-4dea-92b9-003a68d63456",
365
365
  "isHook": false,
366
366
  "skipped": false
367
367
  },
@@ -378,32 +378,32 @@
378
378
  "context": null,
379
379
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n datetime: new Date().toJSON(),\n power_state: 'off'\n });\n })\n });\n yield new Promise(cb => {\n device.once('update:powerState', event => {\n assert.ok(event instanceof NodePyATVDeviceEvent);\n assert.strictEqual(event.key, 'powerState');\n assert.strictEqual(event.oldValue, null);\n assert.strictEqual(event.newValue, 'off');\n assert.strictEqual(event.newValue, NodePyATVPowerState.off);\n assert.strictEqual(event.value, 'off');\n assert.strictEqual(event.value, NodePyATVPowerState.off);\n assert.deepStrictEqual(event.device, device);\n cb(undefined);\n });\n });\n});",
380
380
  "err": {},
381
- "uuid": "69545cc2-bc32-4a6e-8edf-c3f34932ed1d",
382
- "parentUUID": "c9a870f1-d531-43c7-b775-bd09487db80e",
381
+ "uuid": "3a26160d-0467-4c82-9eb6-a72984bf29b5",
382
+ "parentUUID": "7ae68349-5f8b-4dea-92b9-003a68d63456",
383
383
  "isHook": false,
384
384
  "skipped": false
385
385
  }
386
386
  ],
387
387
  "suites": [],
388
388
  "passes": [
389
- "4d0f5ece-7b86-447a-a2f9-41788f9bdb99",
390
- "2fd45f5f-cc18-44ab-9e8a-4f7d55627ca7",
391
- "e18dd8c5-19e9-4165-87a2-139b1e1db475",
392
- "6ffcd02f-fc7e-4cea-8bad-25c22058973e",
393
- "dde29b21-aecb-489f-a114-86cea04781b1",
394
- "fd3c3c76-58cf-4c0f-b69a-03aa8f9bf46a",
395
- "69545cc2-bc32-4a6e-8edf-c3f34932ed1d"
389
+ "678e78f0-675b-4077-a1ca-fcf563573080",
390
+ "2ffa0f11-97f3-47cb-9208-8dbb115481de",
391
+ "a12dff7e-cdea-4f54-a170-53b1a81d23bc",
392
+ "b6fce4a7-de6a-4a1b-91d8-c693dca446f1",
393
+ "8eafbafb-b2dc-44d8-9440-d92ad56d34a8",
394
+ "52e6a084-db78-4ac7-bd3e-a65dde636276",
395
+ "3a26160d-0467-4c82-9eb6-a72984bf29b5"
396
396
  ],
397
397
  "failures": [],
398
398
  "pending": [],
399
399
  "skipped": [],
400
- "duration": 16,
400
+ "duration": 19,
401
401
  "root": false,
402
402
  "rootEmpty": false,
403
403
  "_timeout": 2000
404
404
  },
405
405
  {
406
- "uuid": "ada506a2-1aeb-43b2-894a-72738eabac8a",
406
+ "uuid": "87bb32ff-8254-47df-9496-801bf1276e9f",
407
407
  "title": "start|stopListening()",
408
408
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
409
409
  "file": "/test/device-events.ts",
@@ -414,7 +414,7 @@
414
414
  "title": "should emit error if spawn fails",
415
415
  "fullTitle": "NodePyATVDeviceEvents start|stopListening() should emit error if spawn fails",
416
416
  "timedOut": false,
417
- "duration": 2,
417
+ "duration": 1,
418
418
  "state": "passed",
419
419
  "speed": "fast",
420
420
  "pass": true,
@@ -423,8 +423,8 @@
423
423
  "context": null,
424
424
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const error = new Error();\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.error(error).end();\n })\n });\n const listener = () => {\n // empty listener\n };\n device.on('update', listener);\n yield new Promise(cb => {\n device.once('error', err => {\n assert.strictEqual(err, error);\n cb(undefined);\n });\n });\n device.off('update', listener);\n});",
425
425
  "err": {},
426
- "uuid": "9763fe20-4ca1-4e67-9137-c94d3440d2f7",
427
- "parentUUID": "ada506a2-1aeb-43b2-894a-72738eabac8a",
426
+ "uuid": "d8102947-8908-446d-89b5-6728ffa866d4",
427
+ "parentUUID": "87bb32ff-8254-47df-9496-801bf1276e9f",
428
428
  "isHook": false,
429
429
  "skipped": false
430
430
  },
@@ -432,7 +432,7 @@
432
432
  "title": "should emit error on stderr data",
433
433
  "fullTitle": "NodePyATVDeviceEvents start|stopListening() should emit error on stderr data",
434
434
  "timedOut": false,
435
- "duration": 1,
435
+ "duration": 2,
436
436
  "state": "passed",
437
437
  "speed": "fast",
438
438
  "pass": true,
@@ -441,8 +441,8 @@
441
441
  "context": null,
442
442
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.stderr('Hello World!').end();\n })\n });\n const listener = () => {\n // empty listener\n };\n device.on('update', listener);\n yield new Promise(cb => {\n device.once('error', err => {\n assert.ok(err instanceof Error);\n assert.ok(err.toString().includes('Got stderr output from pyatv: Hello World!'));\n cb(undefined);\n });\n });\n device.off('update', listener);\n});",
443
443
  "err": {},
444
- "uuid": "cfa8e887-4af6-4043-8eab-a7c9fdff88e5",
445
- "parentUUID": "ada506a2-1aeb-43b2-894a-72738eabac8a",
444
+ "uuid": "93e82d07-1a51-400b-bdc9-43ecc54cdabc",
445
+ "parentUUID": "87bb32ff-8254-47df-9496-801bf1276e9f",
446
446
  "isHook": false,
447
447
  "skipped": false
448
448
  },
@@ -450,7 +450,7 @@
450
450
  "title": "should emit error if stdout is not valid json",
451
451
  "fullTitle": "NodePyATVDeviceEvents start|stopListening() should emit error if stdout is not valid json",
452
452
  "timedOut": false,
453
- "duration": 1,
453
+ "duration": 2,
454
454
  "state": "passed",
455
455
  "speed": "fast",
456
456
  "pass": true,
@@ -459,8 +459,8 @@
459
459
  "context": null,
460
460
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.stdout('#').end();\n })\n });\n const listener = () => {\n // empty listener\n };\n device.on('update', listener);\n yield new Promise(cb => {\n device.once('error', err => {\n assert.ok(err instanceof Error);\n assert.ok(err.toString().includes('Unable to parse stdout json: SyntaxError: ' +\n 'Unexpected token # in JSON at position 0'));\n cb(undefined);\n });\n });\n device.off('update', listener);\n});",
461
461
  "err": {},
462
- "uuid": "e5af1eaa-7f67-48f8-9cd7-dc5439427163",
463
- "parentUUID": "ada506a2-1aeb-43b2-894a-72738eabac8a",
462
+ "uuid": "03252cd1-cfd2-4d66-8cb9-027aa94e0ad1",
463
+ "parentUUID": "87bb32ff-8254-47df-9496-801bf1276e9f",
464
464
  "isHook": false,
465
465
  "skipped": false
466
466
  },
@@ -477,30 +477,30 @@
477
477
  "context": null,
478
478
  "code": "",
479
479
  "err": {},
480
- "uuid": "85528f78-e8c4-4556-ba53-a326f4ea6bc1",
481
- "parentUUID": "ada506a2-1aeb-43b2-894a-72738eabac8a",
480
+ "uuid": "23092ad4-d8f3-49cb-a244-d65b99f9d9e7",
481
+ "parentUUID": "87bb32ff-8254-47df-9496-801bf1276e9f",
482
482
  "isHook": false,
483
483
  "skipped": false
484
484
  }
485
485
  ],
486
486
  "suites": [],
487
487
  "passes": [
488
- "9763fe20-4ca1-4e67-9137-c94d3440d2f7",
489
- "cfa8e887-4af6-4043-8eab-a7c9fdff88e5",
490
- "e5af1eaa-7f67-48f8-9cd7-dc5439427163"
488
+ "d8102947-8908-446d-89b5-6728ffa866d4",
489
+ "93e82d07-1a51-400b-bdc9-43ecc54cdabc",
490
+ "03252cd1-cfd2-4d66-8cb9-027aa94e0ad1"
491
491
  ],
492
492
  "failures": [],
493
493
  "pending": [
494
- "85528f78-e8c4-4556-ba53-a326f4ea6bc1"
494
+ "23092ad4-d8f3-49cb-a244-d65b99f9d9e7"
495
495
  ],
496
496
  "skipped": [],
497
- "duration": 4,
497
+ "duration": 5,
498
498
  "root": false,
499
499
  "rootEmpty": false,
500
500
  "_timeout": 2000
501
501
  },
502
502
  {
503
- "uuid": "94222e0e-5097-46fc-ba34-549e838f0b75",
503
+ "uuid": "63c8774a-a822-49c0-bf6b-1e7b0f9a296b",
504
504
  "title": "addListener() / removeAllListeners()",
505
505
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
506
506
  "file": "/test/device-events.ts",
@@ -520,15 +520,15 @@
520
520
  "context": null,
521
521
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n })\n });\n const listener = () => {\n // empty listener\n };\n device.addListener('update', listener);\n device.removeAllListeners('update');\n});",
522
522
  "err": {},
523
- "uuid": "fec3eb71-762f-41b4-aa13-0772f9adb7d8",
524
- "parentUUID": "94222e0e-5097-46fc-ba34-549e838f0b75",
523
+ "uuid": "3f1f9a1d-cdce-4eaf-9ea3-3354970bc868",
524
+ "parentUUID": "63c8774a-a822-49c0-bf6b-1e7b0f9a296b",
525
525
  "isHook": false,
526
526
  "skipped": false
527
527
  }
528
528
  ],
529
529
  "suites": [],
530
530
  "passes": [
531
- "fec3eb71-762f-41b4-aa13-0772f9adb7d8"
531
+ "3f1f9a1d-cdce-4eaf-9ea3-3354970bc868"
532
532
  ],
533
533
  "failures": [],
534
534
  "pending": [],
@@ -539,7 +539,7 @@
539
539
  "_timeout": 2000
540
540
  },
541
541
  {
542
- "uuid": "57de44e8-15f9-4817-b437-dc5f3f4a8a0b",
542
+ "uuid": "66ea85af-044d-4803-bb20-a054b5dc94d8",
543
543
  "title": "emit()",
544
544
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
545
545
  "file": "/test/device-events.ts",
@@ -559,15 +559,15 @@
559
559
  "context": null,
560
560
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n })\n});\nconst event = new NodePyATVDeviceEvent({\n key: 'dateTime',\n old: 'foo',\n new: 'bar',\n device\n});\nlet executions = 0;\ndevice.once('test', (e) => {\n executions++;\n assert.strictEqual(e, event);\n assert.strictEqual(executions, 1);\n done();\n});\ndevice.emit('test', event);",
561
561
  "err": {},
562
- "uuid": "d394075d-c090-4c79-aa53-2b0872dcad71",
563
- "parentUUID": "57de44e8-15f9-4817-b437-dc5f3f4a8a0b",
562
+ "uuid": "5dd207a3-02a2-4f7c-8de1-db86f8e1c050",
563
+ "parentUUID": "66ea85af-044d-4803-bb20-a054b5dc94d8",
564
564
  "isHook": false,
565
565
  "skipped": false
566
566
  }
567
567
  ],
568
568
  "suites": [],
569
569
  "passes": [
570
- "d394075d-c090-4c79-aa53-2b0872dcad71"
570
+ "5dd207a3-02a2-4f7c-8de1-db86f8e1c050"
571
571
  ],
572
572
  "failures": [],
573
573
  "pending": [],
@@ -578,7 +578,7 @@
578
578
  "_timeout": 2000
579
579
  },
580
580
  {
581
- "uuid": "f2c43414-2300-4087-adf6-a7bd36c32fa6",
581
+ "uuid": "c822dee5-4175-4c04-bcbb-4b4291caf15d",
582
582
  "title": "eventNames()",
583
583
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
584
584
  "file": "/test/device-events.ts",
@@ -598,15 +598,15 @@
598
598
  "context": null,
599
599
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n })\n});\nconst listener = () => {\n // ignore\n};\ndevice.on('test', listener);\nassert.deepStrictEqual(device.eventNames(), ['test']);\ndevice.off('test', listener);",
600
600
  "err": {},
601
- "uuid": "3126bdf7-9598-450b-8145-5d1f2c51acec",
602
- "parentUUID": "f2c43414-2300-4087-adf6-a7bd36c32fa6",
601
+ "uuid": "37193c7f-db1d-48c7-9af6-83e94cdf536d",
602
+ "parentUUID": "c822dee5-4175-4c04-bcbb-4b4291caf15d",
603
603
  "isHook": false,
604
604
  "skipped": false
605
605
  }
606
606
  ],
607
607
  "suites": [],
608
608
  "passes": [
609
- "3126bdf7-9598-450b-8145-5d1f2c51acec"
609
+ "37193c7f-db1d-48c7-9af6-83e94cdf536d"
610
610
  ],
611
611
  "failures": [],
612
612
  "pending": [],
@@ -617,7 +617,7 @@
617
617
  "_timeout": 2000
618
618
  },
619
619
  {
620
- "uuid": "6f031d71-bed5-4162-8156-0e1942ec1054",
620
+ "uuid": "2812b534-a752-46bf-8dd5-6dcdefba7107",
621
621
  "title": "getMaxListeners()",
622
622
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
623
623
  "file": "/test/device-events.ts",
@@ -637,15 +637,15 @@
637
637
  "context": null,
638
638
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n })\n});\nconst result = device.getMaxListeners();\nassert.ok(typeof result, 'number');\nassert.ok(result >= 10);",
639
639
  "err": {},
640
- "uuid": "169d31f6-c8bd-4f6d-91b1-7290c7858530",
641
- "parentUUID": "6f031d71-bed5-4162-8156-0e1942ec1054",
640
+ "uuid": "04dd606b-01ec-406d-81d9-8aa94ca10eea",
641
+ "parentUUID": "2812b534-a752-46bf-8dd5-6dcdefba7107",
642
642
  "isHook": false,
643
643
  "skipped": false
644
644
  }
645
645
  ],
646
646
  "suites": [],
647
647
  "passes": [
648
- "169d31f6-c8bd-4f6d-91b1-7290c7858530"
648
+ "04dd606b-01ec-406d-81d9-8aa94ca10eea"
649
649
  ],
650
650
  "failures": [],
651
651
  "pending": [],
@@ -656,7 +656,7 @@
656
656
  "_timeout": 2000
657
657
  },
658
658
  {
659
- "uuid": "25bee3ca-5850-4e97-b1cc-6e999d65a673",
659
+ "uuid": "59f7c1bc-8b0e-405d-bae5-acb09746f267",
660
660
  "title": "listenerCount()",
661
661
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
662
662
  "file": "/test/device-events.ts",
@@ -676,15 +676,15 @@
676
676
  "context": null,
677
677
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n })\n});\nconst listener = () => {\n // ignore\n};\nassert.deepStrictEqual(device.listenerCount('test'), 0);\ndevice.on('test', listener);\nassert.deepStrictEqual(device.listenerCount('test'), 1);\ndevice.off('test', listener);",
678
678
  "err": {},
679
- "uuid": "1fe9e5df-385a-47b9-94e0-176ef5b20a98",
680
- "parentUUID": "25bee3ca-5850-4e97-b1cc-6e999d65a673",
679
+ "uuid": "143b6257-cc57-4532-a4d2-147b37f433e8",
680
+ "parentUUID": "59f7c1bc-8b0e-405d-bae5-acb09746f267",
681
681
  "isHook": false,
682
682
  "skipped": false
683
683
  }
684
684
  ],
685
685
  "suites": [],
686
686
  "passes": [
687
- "1fe9e5df-385a-47b9-94e0-176ef5b20a98"
687
+ "143b6257-cc57-4532-a4d2-147b37f433e8"
688
688
  ],
689
689
  "failures": [],
690
690
  "pending": [],
@@ -695,7 +695,7 @@
695
695
  "_timeout": 2000
696
696
  },
697
697
  {
698
- "uuid": "f96f7007-ed7c-4363-8eb8-2cc682efcd93",
698
+ "uuid": "2853ae14-9c17-4c66-91e1-bd8892d54621",
699
699
  "title": "listeners()",
700
700
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
701
701
  "file": "/test/device-events.ts",
@@ -715,15 +715,15 @@
715
715
  "context": null,
716
716
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n })\n});\nconst listener = () => {\n // ignore\n};\nassert.deepStrictEqual(device.listeners('test').length, 0);\ndevice.on('test', listener);\nassert.deepStrictEqual(device.listeners('test').length, 1);\nassert.deepStrictEqual(device.listeners('test')[0], listener);\ndevice.off('test', listener);",
717
717
  "err": {},
718
- "uuid": "0296fd20-d919-4a13-bfdb-2b97df1b9c14",
719
- "parentUUID": "f96f7007-ed7c-4363-8eb8-2cc682efcd93",
718
+ "uuid": "8b2a3230-9b09-4eb9-aca3-fb89fa7e9cdd",
719
+ "parentUUID": "2853ae14-9c17-4c66-91e1-bd8892d54621",
720
720
  "isHook": false,
721
721
  "skipped": false
722
722
  }
723
723
  ],
724
724
  "suites": [],
725
725
  "passes": [
726
- "0296fd20-d919-4a13-bfdb-2b97df1b9c14"
726
+ "8b2a3230-9b09-4eb9-aca3-fb89fa7e9cdd"
727
727
  ],
728
728
  "failures": [],
729
729
  "pending": [],
@@ -734,7 +734,7 @@
734
734
  "_timeout": 2000
735
735
  },
736
736
  {
737
- "uuid": "5bd13110-cc06-489a-bfc7-91ff1689be47",
737
+ "uuid": "b6c4990f-5394-4acd-aff1-bd68c1116c52",
738
738
  "title": "prependListener()",
739
739
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
740
740
  "file": "/test/device-events.ts",
@@ -754,15 +754,15 @@
754
754
  "context": null,
755
755
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n })\n});\nconst listener = () => {\n device.removeAllListeners('update');\n done();\n};\ndevice.prependListener('update', listener);",
756
756
  "err": {},
757
- "uuid": "90216717-f186-40ce-909e-1b552abc6ce7",
758
- "parentUUID": "5bd13110-cc06-489a-bfc7-91ff1689be47",
757
+ "uuid": "1dcc3d8d-2ba7-4f71-a43f-6e325e05b358",
758
+ "parentUUID": "b6c4990f-5394-4acd-aff1-bd68c1116c52",
759
759
  "isHook": false,
760
760
  "skipped": false
761
761
  }
762
762
  ],
763
763
  "suites": [],
764
764
  "passes": [
765
- "90216717-f186-40ce-909e-1b552abc6ce7"
765
+ "1dcc3d8d-2ba7-4f71-a43f-6e325e05b358"
766
766
  ],
767
767
  "failures": [],
768
768
  "pending": [],
@@ -773,7 +773,7 @@
773
773
  "_timeout": 2000
774
774
  },
775
775
  {
776
- "uuid": "10858261-ea52-4bb3-86fe-9696793ae3ea",
776
+ "uuid": "2bb88472-917f-457b-af79-00db9de2766b",
777
777
  "title": "prependOnceListener()",
778
778
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
779
779
  "file": "/test/device-events.ts",
@@ -784,7 +784,7 @@
784
784
  "title": "should work",
785
785
  "fullTitle": "NodePyATVDeviceEvents prependOnceListener() should work",
786
786
  "timedOut": false,
787
- "duration": 2,
787
+ "duration": 1,
788
788
  "state": "passed",
789
789
  "speed": "fast",
790
790
  "pass": true,
@@ -793,26 +793,26 @@
793
793
  "context": null,
794
794
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n })\n});\ndevice.prependOnceListener('update', () => done());",
795
795
  "err": {},
796
- "uuid": "52e5120e-d6aa-44d6-8423-43c21c892167",
797
- "parentUUID": "10858261-ea52-4bb3-86fe-9696793ae3ea",
796
+ "uuid": "7997cad5-828c-41a8-b440-eccfa8433983",
797
+ "parentUUID": "2bb88472-917f-457b-af79-00db9de2766b",
798
798
  "isHook": false,
799
799
  "skipped": false
800
800
  }
801
801
  ],
802
802
  "suites": [],
803
803
  "passes": [
804
- "52e5120e-d6aa-44d6-8423-43c21c892167"
804
+ "7997cad5-828c-41a8-b440-eccfa8433983"
805
805
  ],
806
806
  "failures": [],
807
807
  "pending": [],
808
808
  "skipped": [],
809
- "duration": 2,
809
+ "duration": 1,
810
810
  "root": false,
811
811
  "rootEmpty": false,
812
812
  "_timeout": 2000
813
813
  },
814
814
  {
815
- "uuid": "b9e1ad34-46ae-4a2a-9f92-54bb931d18fc",
815
+ "uuid": "5901cc70-e555-4cd0-8878-4c0a3d00ad02",
816
816
  "title": "rawListeners()",
817
817
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
818
818
  "file": "/test/device-events.ts",
@@ -823,7 +823,7 @@
823
823
  "title": "should work",
824
824
  "fullTitle": "NodePyATVDeviceEvents rawListeners() should work",
825
825
  "timedOut": false,
826
- "duration": 1,
826
+ "duration": 0,
827
827
  "state": "passed",
828
828
  "speed": "fast",
829
829
  "pass": true,
@@ -832,26 +832,26 @@
832
832
  "context": null,
833
833
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n })\n});\nconst listener = () => {\n // ignore\n};\nassert.deepStrictEqual(device.rawListeners('test').length, 0);\ndevice.on('test', listener);\nassert.deepStrictEqual(device.rawListeners('test').length, 1);\nassert.deepStrictEqual(device.rawListeners('test')[0], listener);\ndevice.off('test', listener);",
834
834
  "err": {},
835
- "uuid": "bcc2c89a-5ba7-4f25-a29c-be3510e06f4c",
836
- "parentUUID": "b9e1ad34-46ae-4a2a-9f92-54bb931d18fc",
835
+ "uuid": "503dc463-f2b3-4494-9daa-29302cb641d5",
836
+ "parentUUID": "5901cc70-e555-4cd0-8878-4c0a3d00ad02",
837
837
  "isHook": false,
838
838
  "skipped": false
839
839
  }
840
840
  ],
841
841
  "suites": [],
842
842
  "passes": [
843
- "bcc2c89a-5ba7-4f25-a29c-be3510e06f4c"
843
+ "503dc463-f2b3-4494-9daa-29302cb641d5"
844
844
  ],
845
845
  "failures": [],
846
846
  "pending": [],
847
847
  "skipped": [],
848
- "duration": 1,
848
+ "duration": 0,
849
849
  "root": false,
850
850
  "rootEmpty": false,
851
851
  "_timeout": 2000
852
852
  },
853
853
  {
854
- "uuid": "2936f502-e562-43d4-b41c-057d575bf073",
854
+ "uuid": "92a978de-b936-4324-afa0-2e98cd29ea77",
855
855
  "title": "removeListener()",
856
856
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device-events.ts",
857
857
  "file": "/test/device-events.ts",
@@ -871,15 +871,15 @@
871
871
  "context": null,
872
872
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.onStdIn(() => cp.end());\n cp.stdout({\n result: 'success',\n title: 'My Movie'\n });\n })\n });\n const listener = () => {\n // empty listener\n };\n device.addListener('update', listener);\n assert.deepStrictEqual(device.listenerCount('update'), 1);\n device.removeListener('update', listener);\n assert.deepStrictEqual(device.listenerCount('update'), 0);\n});",
873
873
  "err": {},
874
- "uuid": "8f35382f-f239-494d-8a83-0b7769aedb9a",
875
- "parentUUID": "2936f502-e562-43d4-b41c-057d575bf073",
874
+ "uuid": "16c2d513-1020-4eb8-bf3a-b5463550ff2d",
875
+ "parentUUID": "92a978de-b936-4324-afa0-2e98cd29ea77",
876
876
  "isHook": false,
877
877
  "skipped": false
878
878
  }
879
879
  ],
880
880
  "suites": [],
881
881
  "passes": [
882
- "8f35382f-f239-494d-8a83-0b7769aedb9a"
882
+ "16c2d513-1020-4eb8-bf3a-b5463550ff2d"
883
883
  ],
884
884
  "failures": [],
885
885
  "pending": [],
@@ -900,7 +900,7 @@
900
900
  "_timeout": 2000
901
901
  },
902
902
  {
903
- "uuid": "46bdae7c-1818-44ba-8b70-71b7569a9924",
903
+ "uuid": "836533ae-1988-4823-8a73-a7a56ecf79f9",
904
904
  "title": "NodePyATVDevice",
905
905
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
906
906
  "file": "/test/device.ts",
@@ -909,7 +909,7 @@
909
909
  "tests": [],
910
910
  "suites": [
911
911
  {
912
- "uuid": "79eb795f-3002-422d-95fd-60c64150390a",
912
+ "uuid": "a87fb88e-f1b9-4316-9541-355ca7129bf1",
913
913
  "title": "get name()",
914
914
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
915
915
  "file": "/test/device.ts",
@@ -929,15 +929,15 @@
929
929
  "context": null,
930
930
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2'\n});\nassert.strictEqual(device.name, 'My Testdevice');",
931
931
  "err": {},
932
- "uuid": "76e283aa-54a9-4f91-accb-fb5afad39deb",
933
- "parentUUID": "79eb795f-3002-422d-95fd-60c64150390a",
932
+ "uuid": "c22e60fa-020e-4eeb-8a9e-67a8089ae961",
933
+ "parentUUID": "a87fb88e-f1b9-4316-9541-355ca7129bf1",
934
934
  "isHook": false,
935
935
  "skipped": false
936
936
  }
937
937
  ],
938
938
  "suites": [],
939
939
  "passes": [
940
- "76e283aa-54a9-4f91-accb-fb5afad39deb"
940
+ "c22e60fa-020e-4eeb-8a9e-67a8089ae961"
941
941
  ],
942
942
  "failures": [],
943
943
  "pending": [],
@@ -948,7 +948,7 @@
948
948
  "_timeout": 2000
949
949
  },
950
950
  {
951
- "uuid": "7fe6028d-1b3b-46b1-a211-d714746d12c4",
951
+ "uuid": "2a6a4b4c-d32f-434f-9341-31c271c936a0",
952
952
  "title": "get host()",
953
953
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
954
954
  "file": "/test/device.ts",
@@ -968,15 +968,15 @@
968
968
  "context": null,
969
969
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2'\n});\nassert.strictEqual(device.host, '192.168.178.2');",
970
970
  "err": {},
971
- "uuid": "9c1624c8-3134-46bd-bc18-8aa022969914",
972
- "parentUUID": "7fe6028d-1b3b-46b1-a211-d714746d12c4",
971
+ "uuid": "c8046d5d-27fc-42fa-92da-ec4c218907e5",
972
+ "parentUUID": "2a6a4b4c-d32f-434f-9341-31c271c936a0",
973
973
  "isHook": false,
974
974
  "skipped": false
975
975
  }
976
976
  ],
977
977
  "suites": [],
978
978
  "passes": [
979
- "9c1624c8-3134-46bd-bc18-8aa022969914"
979
+ "c8046d5d-27fc-42fa-92da-ec4c218907e5"
980
980
  ],
981
981
  "failures": [],
982
982
  "pending": [],
@@ -987,7 +987,7 @@
987
987
  "_timeout": 2000
988
988
  },
989
989
  {
990
- "uuid": "b99c2916-e647-4392-98bb-285119adabe9",
990
+ "uuid": "fa8911dc-573c-4366-84e0-6fe11ec677bb",
991
991
  "title": "get id()",
992
992
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
993
993
  "file": "/test/device.ts",
@@ -1007,15 +1007,15 @@
1007
1007
  "context": null,
1008
1008
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n id: '*****'\n});\nassert.strictEqual(device.id, '*****');",
1009
1009
  "err": {},
1010
- "uuid": "bd718197-7af8-4af8-ae14-b536d1e90995",
1011
- "parentUUID": "b99c2916-e647-4392-98bb-285119adabe9",
1010
+ "uuid": "8fb5c723-f919-4582-84f3-22d4a15f0137",
1011
+ "parentUUID": "fa8911dc-573c-4366-84e0-6fe11ec677bb",
1012
1012
  "isHook": false,
1013
1013
  "skipped": false
1014
1014
  }
1015
1015
  ],
1016
1016
  "suites": [],
1017
1017
  "passes": [
1018
- "bd718197-7af8-4af8-ae14-b536d1e90995"
1018
+ "8fb5c723-f919-4582-84f3-22d4a15f0137"
1019
1019
  ],
1020
1020
  "failures": [],
1021
1021
  "pending": [],
@@ -1026,7 +1026,7 @@
1026
1026
  "_timeout": 2000
1027
1027
  },
1028
1028
  {
1029
- "uuid": "77927de0-d73a-4854-95ec-aa26f07c47bf",
1029
+ "uuid": "d42b269b-5355-4890-af8c-88b9c7ea5f29",
1030
1030
  "title": "get protocol()",
1031
1031
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1032
1032
  "file": "/test/device.ts",
@@ -1037,7 +1037,7 @@
1037
1037
  "title": "should return the protocol",
1038
1038
  "fullTitle": "NodePyATVDevice get protocol() should return the protocol",
1039
1039
  "timedOut": false,
1040
- "duration": 0,
1040
+ "duration": 1,
1041
1041
  "state": "passed",
1042
1042
  "speed": "fast",
1043
1043
  "pass": true,
@@ -1046,26 +1046,26 @@
1046
1046
  "context": null,
1047
1047
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n protocol: NodePyATVProtocol.airplay\n});\nassert.strictEqual(device.protocol, NodePyATVProtocol.airplay);",
1048
1048
  "err": {},
1049
- "uuid": "30f1a647-6bfc-4b28-9142-856dbb468ee0",
1050
- "parentUUID": "77927de0-d73a-4854-95ec-aa26f07c47bf",
1049
+ "uuid": "6463bbfa-ba21-4f9d-8e80-5996cda9e1d5",
1050
+ "parentUUID": "d42b269b-5355-4890-af8c-88b9c7ea5f29",
1051
1051
  "isHook": false,
1052
1052
  "skipped": false
1053
1053
  }
1054
1054
  ],
1055
1055
  "suites": [],
1056
1056
  "passes": [
1057
- "30f1a647-6bfc-4b28-9142-856dbb468ee0"
1057
+ "6463bbfa-ba21-4f9d-8e80-5996cda9e1d5"
1058
1058
  ],
1059
1059
  "failures": [],
1060
1060
  "pending": [],
1061
1061
  "skipped": [],
1062
- "duration": 0,
1062
+ "duration": 1,
1063
1063
  "root": false,
1064
1064
  "rootEmpty": false,
1065
1065
  "_timeout": 2000
1066
1066
  },
1067
1067
  {
1068
- "uuid": "42a5b940-9052-45e6-b4bb-2dae2cee0875",
1068
+ "uuid": "e6498f99-2eb5-4629-a2f5-b12d0854d3a9",
1069
1069
  "title": "get model()",
1070
1070
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1071
1071
  "file": "/test/device.ts",
@@ -1085,8 +1085,8 @@
1085
1085
  "context": null,
1086
1086
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81',\n id: 'xxx',\n model: 'Gen4K'\n});\nassert.strictEqual(device.model, 'Gen4K');",
1087
1087
  "err": {},
1088
- "uuid": "3315b3ff-3b70-444d-9f3e-6ee61c177efd",
1089
- "parentUUID": "42a5b940-9052-45e6-b4bb-2dae2cee0875",
1088
+ "uuid": "6eddb22f-34da-4f7c-b6e0-303f9d341b1f",
1089
+ "parentUUID": "e6498f99-2eb5-4629-a2f5-b12d0854d3a9",
1090
1090
  "isHook": false,
1091
1091
  "skipped": false
1092
1092
  },
@@ -1103,16 +1103,16 @@
1103
1103
  "context": null,
1104
1104
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81'\n});\nassert.strictEqual(device.model, undefined);",
1105
1105
  "err": {},
1106
- "uuid": "5848a8e3-32b9-447d-851d-7b3ded941e34",
1107
- "parentUUID": "42a5b940-9052-45e6-b4bb-2dae2cee0875",
1106
+ "uuid": "f67693ed-ee6e-4912-8a70-6b0eab3f707a",
1107
+ "parentUUID": "e6498f99-2eb5-4629-a2f5-b12d0854d3a9",
1108
1108
  "isHook": false,
1109
1109
  "skipped": false
1110
1110
  }
1111
1111
  ],
1112
1112
  "suites": [],
1113
1113
  "passes": [
1114
- "3315b3ff-3b70-444d-9f3e-6ee61c177efd",
1115
- "5848a8e3-32b9-447d-851d-7b3ded941e34"
1114
+ "6eddb22f-34da-4f7c-b6e0-303f9d341b1f",
1115
+ "f67693ed-ee6e-4912-8a70-6b0eab3f707a"
1116
1116
  ],
1117
1117
  "failures": [],
1118
1118
  "pending": [],
@@ -1123,7 +1123,7 @@
1123
1123
  "_timeout": 2000
1124
1124
  },
1125
1125
  {
1126
- "uuid": "23db4b4a-030d-46d9-8e29-ee35bb1c06fb",
1126
+ "uuid": "eb5713c1-309b-4cc4-a358-6dfae3398e54",
1127
1127
  "title": "get modelName()",
1128
1128
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1129
1129
  "file": "/test/device.ts",
@@ -1143,8 +1143,8 @@
1143
1143
  "context": null,
1144
1144
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81',\n id: 'xxx',\n modelName: 'Apple TV 4K'\n});\nassert.strictEqual(device.modelName, 'Apple TV 4K');",
1145
1145
  "err": {},
1146
- "uuid": "ce96cd5f-2c7f-42f2-8dbb-546a1a0e8a8a",
1147
- "parentUUID": "23db4b4a-030d-46d9-8e29-ee35bb1c06fb",
1146
+ "uuid": "5f3f3260-1ed3-4126-9ac6-1297ad1d74eb",
1147
+ "parentUUID": "eb5713c1-309b-4cc4-a358-6dfae3398e54",
1148
1148
  "isHook": false,
1149
1149
  "skipped": false
1150
1150
  },
@@ -1161,16 +1161,16 @@
1161
1161
  "context": null,
1162
1162
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81'\n});\nassert.strictEqual(device.modelName, undefined);",
1163
1163
  "err": {},
1164
- "uuid": "c74275a9-b0d0-4202-8f26-ec43598e11cd",
1165
- "parentUUID": "23db4b4a-030d-46d9-8e29-ee35bb1c06fb",
1164
+ "uuid": "2a444b3d-47e3-40f2-8867-ad8965dcc35c",
1165
+ "parentUUID": "eb5713c1-309b-4cc4-a358-6dfae3398e54",
1166
1166
  "isHook": false,
1167
1167
  "skipped": false
1168
1168
  }
1169
1169
  ],
1170
1170
  "suites": [],
1171
1171
  "passes": [
1172
- "ce96cd5f-2c7f-42f2-8dbb-546a1a0e8a8a",
1173
- "c74275a9-b0d0-4202-8f26-ec43598e11cd"
1172
+ "5f3f3260-1ed3-4126-9ac6-1297ad1d74eb",
1173
+ "2a444b3d-47e3-40f2-8867-ad8965dcc35c"
1174
1174
  ],
1175
1175
  "failures": [],
1176
1176
  "pending": [],
@@ -1181,7 +1181,7 @@
1181
1181
  "_timeout": 2000
1182
1182
  },
1183
1183
  {
1184
- "uuid": "e0c2555f-e42c-48c9-9263-94a814af7447",
1184
+ "uuid": "21c59f49-4570-453b-aa01-12f8dc3c41ac",
1185
1185
  "title": "get os()",
1186
1186
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1187
1187
  "file": "/test/device.ts",
@@ -1201,8 +1201,8 @@
1201
1201
  "context": null,
1202
1202
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81',\n id: 'xxx',\n os: 'TvOS'\n});\nassert.strictEqual(device.os, 'TvOS');",
1203
1203
  "err": {},
1204
- "uuid": "267a800b-f9e9-4033-a6ff-b0697236af30",
1205
- "parentUUID": "e0c2555f-e42c-48c9-9263-94a814af7447",
1204
+ "uuid": "f7138ec5-d324-4c81-9ec2-91e8d70b517a",
1205
+ "parentUUID": "21c59f49-4570-453b-aa01-12f8dc3c41ac",
1206
1206
  "isHook": false,
1207
1207
  "skipped": false
1208
1208
  },
@@ -1219,16 +1219,16 @@
1219
1219
  "context": null,
1220
1220
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81'\n});\nassert.strictEqual(device.os, undefined);",
1221
1221
  "err": {},
1222
- "uuid": "f740657f-c0e1-4042-b5f0-79176369dfe0",
1223
- "parentUUID": "e0c2555f-e42c-48c9-9263-94a814af7447",
1222
+ "uuid": "1034d80d-5d37-444b-9ac1-ea8c9256194f",
1223
+ "parentUUID": "21c59f49-4570-453b-aa01-12f8dc3c41ac",
1224
1224
  "isHook": false,
1225
1225
  "skipped": false
1226
1226
  }
1227
1227
  ],
1228
1228
  "suites": [],
1229
1229
  "passes": [
1230
- "267a800b-f9e9-4033-a6ff-b0697236af30",
1231
- "f740657f-c0e1-4042-b5f0-79176369dfe0"
1230
+ "f7138ec5-d324-4c81-9ec2-91e8d70b517a",
1231
+ "1034d80d-5d37-444b-9ac1-ea8c9256194f"
1232
1232
  ],
1233
1233
  "failures": [],
1234
1234
  "pending": [],
@@ -1239,7 +1239,7 @@
1239
1239
  "_timeout": 2000
1240
1240
  },
1241
1241
  {
1242
- "uuid": "de4bf437-fea9-4766-bff7-a82481264a6a",
1242
+ "uuid": "e06dbf0d-2399-4da0-bf6e-2d50c2b94bc0",
1243
1243
  "title": "get version()",
1244
1244
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1245
1245
  "file": "/test/device.ts",
@@ -1259,8 +1259,8 @@
1259
1259
  "context": null,
1260
1260
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81',\n id: 'xxx',\n version: '15.5.1'\n});\nassert.strictEqual(device.version, '15.5.1');",
1261
1261
  "err": {},
1262
- "uuid": "f981ffb9-d521-4aca-932c-f931dd72f123",
1263
- "parentUUID": "de4bf437-fea9-4766-bff7-a82481264a6a",
1262
+ "uuid": "5f3bc300-99ba-4c2c-8dcd-30c9d7b18e9d",
1263
+ "parentUUID": "e06dbf0d-2399-4da0-bf6e-2d50c2b94bc0",
1264
1264
  "isHook": false,
1265
1265
  "skipped": false
1266
1266
  },
@@ -1277,16 +1277,16 @@
1277
1277
  "context": null,
1278
1278
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81'\n});\nassert.strictEqual(device.version, undefined);",
1279
1279
  "err": {},
1280
- "uuid": "eb1d70b3-0b24-4465-9155-fa5dcca56e4a",
1281
- "parentUUID": "de4bf437-fea9-4766-bff7-a82481264a6a",
1280
+ "uuid": "784b1c46-a7c0-44e2-a157-8292199ae9ad",
1281
+ "parentUUID": "e06dbf0d-2399-4da0-bf6e-2d50c2b94bc0",
1282
1282
  "isHook": false,
1283
1283
  "skipped": false
1284
1284
  }
1285
1285
  ],
1286
1286
  "suites": [],
1287
1287
  "passes": [
1288
- "f981ffb9-d521-4aca-932c-f931dd72f123",
1289
- "eb1d70b3-0b24-4465-9155-fa5dcca56e4a"
1288
+ "5f3bc300-99ba-4c2c-8dcd-30c9d7b18e9d",
1289
+ "784b1c46-a7c0-44e2-a157-8292199ae9ad"
1290
1290
  ],
1291
1291
  "failures": [],
1292
1292
  "pending": [],
@@ -1297,7 +1297,7 @@
1297
1297
  "_timeout": 2000
1298
1298
  },
1299
1299
  {
1300
- "uuid": "548fa4fc-d897-455c-95db-a45083f94349",
1300
+ "uuid": "7b098050-ea05-4f8b-8322-fb84fb20f49f",
1301
1301
  "title": "get services()",
1302
1302
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1303
1303
  "file": "/test/device.ts",
@@ -1317,8 +1317,8 @@
1317
1317
  "context": null,
1318
1318
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81',\n id: 'xxx',\n services: [\n {\n protocol: NodePyATVProtocol.mrp,\n port: 49152\n },\n {\n protocol: NodePyATVProtocol.airplay,\n port: 7000\n }\n ]\n});\nassert.deepStrictEqual(device.services, [\n {\n protocol: 'mrp',\n port: 49152\n },\n {\n protocol: 'airplay',\n port: 7000\n }\n]);",
1319
1319
  "err": {},
1320
- "uuid": "460b9247-52fd-4620-8e52-34a5c7c33cfa",
1321
- "parentUUID": "548fa4fc-d897-455c-95db-a45083f94349",
1320
+ "uuid": "98adbb7f-e450-471d-bc38-e67cf8962213",
1321
+ "parentUUID": "7b098050-ea05-4f8b-8322-fb84fb20f49f",
1322
1322
  "isHook": false,
1323
1323
  "skipped": false
1324
1324
  },
@@ -1335,16 +1335,16 @@
1335
1335
  "context": null,
1336
1336
  "code": "const device = new NodePyATVDevice({\n name: 'Vardagsrum',\n host: '10.0.10.81'\n});\nassert.strictEqual(device.services, undefined);",
1337
1337
  "err": {},
1338
- "uuid": "13381fa9-5672-4086-8e65-6ec0fff4890b",
1339
- "parentUUID": "548fa4fc-d897-455c-95db-a45083f94349",
1338
+ "uuid": "714ca225-b719-49a0-aa38-712a68fbfe52",
1339
+ "parentUUID": "7b098050-ea05-4f8b-8322-fb84fb20f49f",
1340
1340
  "isHook": false,
1341
1341
  "skipped": false
1342
1342
  }
1343
1343
  ],
1344
1344
  "suites": [],
1345
1345
  "passes": [
1346
- "460b9247-52fd-4620-8e52-34a5c7c33cfa",
1347
- "13381fa9-5672-4086-8e65-6ec0fff4890b"
1346
+ "98adbb7f-e450-471d-bc38-e67cf8962213",
1347
+ "714ca225-b719-49a0-aa38-712a68fbfe52"
1348
1348
  ],
1349
1349
  "failures": [],
1350
1350
  "pending": [],
@@ -1355,7 +1355,7 @@
1355
1355
  "_timeout": 2000
1356
1356
  },
1357
1357
  {
1358
- "uuid": "4245f5ee-1550-48b6-bd0c-0a5e949905fe",
1358
+ "uuid": "8f3b0506-708b-4893-8b95-8ff0e9cbbe97",
1359
1359
  "title": "get debug()",
1360
1360
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1361
1361
  "file": "/test/device.ts",
@@ -1375,8 +1375,8 @@
1375
1375
  "context": null,
1376
1376
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n debug: true\n});\nassert.strictEqual(device.debug, true);",
1377
1377
  "err": {},
1378
- "uuid": "480e6bec-cdd7-4234-ae51-ebb30ce33df9",
1379
- "parentUUID": "4245f5ee-1550-48b6-bd0c-0a5e949905fe",
1378
+ "uuid": "ae4dd216-6612-4608-9c3f-7a69b89982f3",
1379
+ "parentUUID": "8f3b0506-708b-4893-8b95-8ff0e9cbbe97",
1380
1380
  "isHook": false,
1381
1381
  "skipped": false
1382
1382
  },
@@ -1393,8 +1393,8 @@
1393
1393
  "context": null,
1394
1394
  "code": "// eslint-disable-next-line @typescript-eslint/no-empty-function\nconst fn = () => {\n};\nconst device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n debug: fn\n});\nassert.strictEqual(device.debug, fn);",
1395
1395
  "err": {},
1396
- "uuid": "79d22445-d046-4d89-9b36-b5ec872f94f2",
1397
- "parentUUID": "4245f5ee-1550-48b6-bd0c-0a5e949905fe",
1396
+ "uuid": "8ea0ca6b-0a9d-435e-83b5-33a4f9fd8633",
1397
+ "parentUUID": "8f3b0506-708b-4893-8b95-8ff0e9cbbe97",
1398
1398
  "isHook": false,
1399
1399
  "skipped": false
1400
1400
  },
@@ -1411,17 +1411,17 @@
1411
1411
  "context": null,
1412
1412
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2'\n});\nassert.strictEqual(device.debug, undefined);",
1413
1413
  "err": {},
1414
- "uuid": "a1558aa7-a1cc-48d9-b486-1613c3ad4d9a",
1415
- "parentUUID": "4245f5ee-1550-48b6-bd0c-0a5e949905fe",
1414
+ "uuid": "62bbbe56-1a57-4bf9-90db-a1d8da7ce13a",
1415
+ "parentUUID": "8f3b0506-708b-4893-8b95-8ff0e9cbbe97",
1416
1416
  "isHook": false,
1417
1417
  "skipped": false
1418
1418
  }
1419
1419
  ],
1420
1420
  "suites": [],
1421
1421
  "passes": [
1422
- "480e6bec-cdd7-4234-ae51-ebb30ce33df9",
1423
- "79d22445-d046-4d89-9b36-b5ec872f94f2",
1424
- "a1558aa7-a1cc-48d9-b486-1613c3ad4d9a"
1422
+ "ae4dd216-6612-4608-9c3f-7a69b89982f3",
1423
+ "8ea0ca6b-0a9d-435e-83b5-33a4f9fd8633",
1424
+ "62bbbe56-1a57-4bf9-90db-a1d8da7ce13a"
1425
1425
  ],
1426
1426
  "failures": [],
1427
1427
  "pending": [],
@@ -1432,7 +1432,7 @@
1432
1432
  "_timeout": 2000
1433
1433
  },
1434
1434
  {
1435
- "uuid": "a7d79413-3409-470a-ac21-b1ddfc43f07a",
1435
+ "uuid": "9c060e75-9954-4f57-9cf6-e390bc12d3e9",
1436
1436
  "title": "set debug()",
1437
1437
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1438
1438
  "file": "/test/device.ts",
@@ -1452,8 +1452,8 @@
1452
1452
  "context": null,
1453
1453
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2'\n});\nassert.strictEqual(device.debug, undefined);\ndevice.debug = true;\nassert.strictEqual(device.debug, true);",
1454
1454
  "err": {},
1455
- "uuid": "864368cf-32ad-44ac-8f65-2c4a9eafd094",
1456
- "parentUUID": "a7d79413-3409-470a-ac21-b1ddfc43f07a",
1455
+ "uuid": "c6f0fb8d-a459-4305-863d-819251d29f3d",
1456
+ "parentUUID": "9c060e75-9954-4f57-9cf6-e390bc12d3e9",
1457
1457
  "isHook": false,
1458
1458
  "skipped": false
1459
1459
  },
@@ -1470,8 +1470,8 @@
1470
1470
  "context": null,
1471
1471
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n debug: true\n});\nassert.strictEqual(device.debug, true);\ndevice.debug = undefined;\nassert.strictEqual(device.debug, undefined);",
1472
1472
  "err": {},
1473
- "uuid": "d64efa62-2cfa-481b-b703-11d754cd765a",
1474
- "parentUUID": "a7d79413-3409-470a-ac21-b1ddfc43f07a",
1473
+ "uuid": "f04d9743-8877-4f3c-9daa-82f3bf536312",
1474
+ "parentUUID": "9c060e75-9954-4f57-9cf6-e390bc12d3e9",
1475
1475
  "isHook": false,
1476
1476
  "skipped": false
1477
1477
  },
@@ -1488,8 +1488,8 @@
1488
1488
  "context": null,
1489
1489
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n debug: true\n});\nassert.strictEqual(device.debug, true);\ndevice.debug = undefined;\nassert.strictEqual(device.debug, undefined);",
1490
1490
  "err": {},
1491
- "uuid": "ed618132-9f10-4397-919f-9ad9292ebefa",
1492
- "parentUUID": "a7d79413-3409-470a-ac21-b1ddfc43f07a",
1491
+ "uuid": "1aa1f999-93d7-4ae4-b2f6-df4fc6c758b4",
1492
+ "parentUUID": "9c060e75-9954-4f57-9cf6-e390bc12d3e9",
1493
1493
  "isHook": false,
1494
1494
  "skipped": false
1495
1495
  },
@@ -1497,7 +1497,7 @@
1497
1497
  "title": "should work for debug = fn",
1498
1498
  "fullTitle": "NodePyATVDevice set debug() should work for debug = fn",
1499
1499
  "timedOut": false,
1500
- "duration": 0,
1500
+ "duration": 1,
1501
1501
  "state": "passed",
1502
1502
  "speed": "fast",
1503
1503
  "pass": true,
@@ -1506,29 +1506,29 @@
1506
1506
  "context": null,
1507
1507
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2'\n});\n// eslint-disable-next-line @typescript-eslint/no-empty-function\nconst fn = () => {\n};\nassert.strictEqual(device.debug, undefined);\ndevice.debug = fn;\nassert.strictEqual(device.debug, fn);",
1508
1508
  "err": {},
1509
- "uuid": "dbbd5e59-d5da-4c1f-8cfb-00ad679d3268",
1510
- "parentUUID": "a7d79413-3409-470a-ac21-b1ddfc43f07a",
1509
+ "uuid": "3a97c40d-b2c1-4ebc-a0c8-0e44010d8d05",
1510
+ "parentUUID": "9c060e75-9954-4f57-9cf6-e390bc12d3e9",
1511
1511
  "isHook": false,
1512
1512
  "skipped": false
1513
1513
  }
1514
1514
  ],
1515
1515
  "suites": [],
1516
1516
  "passes": [
1517
- "864368cf-32ad-44ac-8f65-2c4a9eafd094",
1518
- "d64efa62-2cfa-481b-b703-11d754cd765a",
1519
- "ed618132-9f10-4397-919f-9ad9292ebefa",
1520
- "dbbd5e59-d5da-4c1f-8cfb-00ad679d3268"
1517
+ "c6f0fb8d-a459-4305-863d-819251d29f3d",
1518
+ "f04d9743-8877-4f3c-9daa-82f3bf536312",
1519
+ "1aa1f999-93d7-4ae4-b2f6-df4fc6c758b4",
1520
+ "3a97c40d-b2c1-4ebc-a0c8-0e44010d8d05"
1521
1521
  ],
1522
1522
  "failures": [],
1523
1523
  "pending": [],
1524
1524
  "skipped": [],
1525
- "duration": 0,
1525
+ "duration": 1,
1526
1526
  "root": false,
1527
1527
  "rootEmpty": false,
1528
1528
  "_timeout": 2000
1529
1529
  },
1530
1530
  {
1531
- "uuid": "e9e22da7-a9da-4c3c-b69c-e37f27a26505",
1531
+ "uuid": "88fdae22-2e47-4491-a297-aa8e0f661e99",
1532
1532
  "title": "toJSON()",
1533
1533
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1534
1534
  "file": "/test/device.ts",
@@ -1548,8 +1548,8 @@
1548
1548
  "context": null,
1549
1549
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n id: '*****',\n protocol: NodePyATVProtocol.airplay\n});\nassert.deepEqual(device.toJSON(), {\n name: 'My Testdevice',\n host: '192.168.178.2',\n id: '*****',\n protocol: NodePyATVProtocol.airplay\n});",
1550
1550
  "err": {},
1551
- "uuid": "88f6bea5-2440-475f-a05c-1a464b66d340",
1552
- "parentUUID": "e9e22da7-a9da-4c3c-b69c-e37f27a26505",
1551
+ "uuid": "a183360b-ec9c-41ff-9743-5191e691119d",
1552
+ "parentUUID": "88fdae22-2e47-4491-a297-aa8e0f661e99",
1553
1553
  "isHook": false,
1554
1554
  "skipped": false
1555
1555
  },
@@ -1566,16 +1566,16 @@
1566
1566
  "context": null,
1567
1567
  "code": "const config = {\n name: 'My Testdevice',\n host: '192.168.178.2',\n id: '*****',\n protocol: NodePyATVProtocol.airplay\n};\nconst deviceA = new NodePyATVDevice(config);\nconst deviceB = new NodePyATVDevice(deviceA.toJSON());\nassert.deepEqual(deviceB.toJSON(), config);",
1568
1568
  "err": {},
1569
- "uuid": "c8d34510-0712-468b-9f91-c130d7888cd3",
1570
- "parentUUID": "e9e22da7-a9da-4c3c-b69c-e37f27a26505",
1569
+ "uuid": "69e2a5c7-e08c-46e2-884e-74d9600fdbae",
1570
+ "parentUUID": "88fdae22-2e47-4491-a297-aa8e0f661e99",
1571
1571
  "isHook": false,
1572
1572
  "skipped": false
1573
1573
  }
1574
1574
  ],
1575
1575
  "suites": [],
1576
1576
  "passes": [
1577
- "88f6bea5-2440-475f-a05c-1a464b66d340",
1578
- "c8d34510-0712-468b-9f91-c130d7888cd3"
1577
+ "a183360b-ec9c-41ff-9743-5191e691119d",
1578
+ "69e2a5c7-e08c-46e2-884e-74d9600fdbae"
1579
1579
  ],
1580
1580
  "failures": [],
1581
1581
  "pending": [],
@@ -1586,7 +1586,7 @@
1586
1586
  "_timeout": 2000
1587
1587
  },
1588
1588
  {
1589
- "uuid": "a0215879-5f8a-473f-bee5-c2a8c7295e08",
1589
+ "uuid": "7a171968-c4e2-4a83-85d2-f94cb880dbe4",
1590
1590
  "title": "toString()",
1591
1591
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1592
1592
  "file": "/test/device.ts",
@@ -1597,7 +1597,7 @@
1597
1597
  "title": "should work",
1598
1598
  "fullTitle": "NodePyATVDevice toString() should work",
1599
1599
  "timedOut": false,
1600
- "duration": 0,
1600
+ "duration": 1,
1601
1601
  "state": "passed",
1602
1602
  "speed": "fast",
1603
1603
  "pass": true,
@@ -1606,26 +1606,26 @@
1606
1606
  "context": null,
1607
1607
  "code": "const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2'\n});\nassert.strictEqual(device.toString(), 'NodePyATVDevice(My Testdevice, 192.168.178.2)');",
1608
1608
  "err": {},
1609
- "uuid": "bf1b4bd9-0bb8-4a0e-925d-233042da3204",
1610
- "parentUUID": "a0215879-5f8a-473f-bee5-c2a8c7295e08",
1609
+ "uuid": "69242bc6-7d6a-47d5-8ba7-377215c62bd6",
1610
+ "parentUUID": "7a171968-c4e2-4a83-85d2-f94cb880dbe4",
1611
1611
  "isHook": false,
1612
1612
  "skipped": false
1613
1613
  }
1614
1614
  ],
1615
1615
  "suites": [],
1616
1616
  "passes": [
1617
- "bf1b4bd9-0bb8-4a0e-925d-233042da3204"
1617
+ "69242bc6-7d6a-47d5-8ba7-377215c62bd6"
1618
1618
  ],
1619
1619
  "failures": [],
1620
1620
  "pending": [],
1621
1621
  "skipped": [],
1622
- "duration": 0,
1622
+ "duration": 1,
1623
1623
  "root": false,
1624
1624
  "rootEmpty": false,
1625
1625
  "_timeout": 2000
1626
1626
  },
1627
1627
  {
1628
- "uuid": "ab620283-6275-40c9-9fa5-90e7c5a2f0e3",
1628
+ "uuid": "40ef3f02-56e9-4d03-ac1d-ebc8211c4432",
1629
1629
  "title": "getState()",
1630
1630
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1631
1631
  "file": "/test/device.ts",
@@ -1645,8 +1645,8 @@
1645
1645
  "context": null,
1646
1646
  "code": "",
1647
1647
  "err": {},
1648
- "uuid": "0155af3a-89b3-458e-8584-608bfdf638b2",
1649
- "parentUUID": "ab620283-6275-40c9-9fa5-90e7c5a2f0e3",
1648
+ "uuid": "ebae24fc-62b9-45e8-a73a-31753cbb8ee0",
1649
+ "parentUUID": "40ef3f02-56e9-4d03-ac1d-ebc8211c4432",
1650
1650
  "isHook": false,
1651
1651
  "skipped": false
1652
1652
  },
@@ -1663,8 +1663,8 @@
1663
1663
  "context": null,
1664
1664
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n datetime: '2020-11-07T22:38:43.608030+01:00',\n hash: '100e0ab6-6ff5-4199-9c04-a7107ff78712',\n media_type: 'video',\n device_state: 'playing',\n title: 'Solo: A Star Wars Story',\n artist: null,\n album: null,\n genre: null,\n total_time: 8097,\n position: 27,\n shuffle: 'off',\n repeat: 'off',\n app: 'Disney+',\n app_id: 'com.disney.disneyplus'\n });\n })\n });\n const result = yield device.getState();\n assert.deepStrictEqual(result, {\n dateTime: new Date('2020-11-07T22:38:43.608030+01:00'),\n hash: '100e0ab6-6ff5-4199-9c04-a7107ff78712',\n mediaType: NodePyATVMediaType.video,\n deviceState: NodePyATVDeviceState.playing,\n title: 'Solo: A Star Wars Story',\n artist: null,\n album: null,\n genre: null,\n totalTime: 8097,\n position: 27,\n shuffle: NodePyATVShuffleState.off,\n repeat: NodePyATVRepeatState.off,\n app: 'Disney+',\n appId: 'com.disney.disneyplus',\n powerState: null\n });\n});",
1665
1665
  "err": {},
1666
- "uuid": "72e17372-c1de-4354-84bf-e507e2c86339",
1667
- "parentUUID": "ab620283-6275-40c9-9fa5-90e7c5a2f0e3",
1666
+ "uuid": "e9999976-2b9f-4921-9ba0-51bcf5d7fe36",
1667
+ "parentUUID": "40ef3f02-56e9-4d03-ac1d-ebc8211c4432",
1668
1668
  "isHook": false,
1669
1669
  "skipped": false
1670
1670
  },
@@ -1681,8 +1681,8 @@
1681
1681
  "context": null,
1682
1682
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'failure',\n datetime: '2021-11-24T21:13:36.424576+03:00',\n exception: 'invalid credentials: 321',\n stacktrace: 'Traceback (most recent call last):\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/scripts/atvscript.py\\\", line 302, in appstart\\n print(args.output(await _handle_command(args, abort_sem, loop)), flush=True)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/scripts/atvscript.py\\\", line 196, in _handle_command\\n atv = await connect(config, loop, protocol=Protocol.MRP)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/__init__.py\\\", line 96, in connect\\n for setup_data in proto_methods.setup(\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/protocols/airplay/__init__.py\\\", line 192, in setup\\n stream = AirPlayStream(config, service)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/protocols/airplay/__init__.py\\\", line 79, in __init__\\n self._credentials: HapCredentials = parse_credentials(self.service.credentials)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/auth/hap_pairing.py\\\", line 139, in parse_credentials\\n raise exceptions.InvalidCredentialsError(\\\"invalid credentials: \\\" + detail_string)\\npyatv.exceptions.InvalidCredentialsError: invalid credentials: 321\\n'\n });\n })\n });\n assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield device.getState();\n }), /Got pyatv Error: invalid credentials: 321/);\n});",
1683
1683
  "err": {},
1684
- "uuid": "aad79c5d-2269-4dab-8bcc-a93efe04b38d",
1685
- "parentUUID": "ab620283-6275-40c9-9fa5-90e7c5a2f0e3",
1684
+ "uuid": "3f443421-180a-42a3-b03a-961b9cd2b472",
1685
+ "parentUUID": "40ef3f02-56e9-4d03-ac1d-ebc8211c4432",
1686
1686
  "isHook": false,
1687
1687
  "skipped": false
1688
1688
  },
@@ -1690,7 +1690,7 @@
1690
1690
  "title": "should cache requests for a bit",
1691
1691
  "fullTitle": "NodePyATVDevice getState() should cache requests for a bit",
1692
1692
  "timedOut": false,
1693
- "duration": 3,
1693
+ "duration": 2,
1694
1694
  "state": "passed",
1695
1695
  "speed": "fast",
1696
1696
  "pass": true,
@@ -1699,8 +1699,8 @@
1699
1699
  "context": null,
1700
1700
  "code": "return __awaiter(this, void 0, void 0, function* () {\n let executions = 0;\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n executions++;\n cp.end({\n result: 'success',\n datetime: new Date().toJSON(),\n hash: '100e0ab6-6ff5-4199-9c04-a7107ff78712',\n media_type: 'video',\n device_state: 'playing',\n title: 'Solo: A Star Wars Story',\n artist: null,\n album: null,\n genre: null,\n total_time: 8097,\n position: 27,\n shuffle: 'off',\n repeat: 'off',\n app: 'Disney+',\n app_id: 'com.disney.disneyplus'\n });\n })\n });\n const firstResult = yield device.getState();\n const secondResult = yield device.getState();\n assert.strictEqual(firstResult.dateTime, secondResult.dateTime);\n assert.strictEqual(executions, 1);\n});",
1701
1701
  "err": {},
1702
- "uuid": "7107d353-049e-4bc0-842b-9028d7fa8dab",
1703
- "parentUUID": "ab620283-6275-40c9-9fa5-90e7c5a2f0e3",
1702
+ "uuid": "74afba0a-3c48-4b76-8b6f-4b8bea6232d9",
1703
+ "parentUUID": "40ef3f02-56e9-4d03-ac1d-ebc8211c4432",
1704
1704
  "isHook": false,
1705
1705
  "skipped": false
1706
1706
  },
@@ -1708,7 +1708,7 @@
1708
1708
  "title": "should update the position if cache was used",
1709
1709
  "fullTitle": "NodePyATVDevice getState() should update the position if cache was used",
1710
1710
  "timedOut": false,
1711
- "duration": 1,
1711
+ "duration": 2,
1712
1712
  "state": "passed",
1713
1713
  "speed": "fast",
1714
1714
  "pass": true,
@@ -1717,22 +1717,22 @@
1717
1717
  "context": null,
1718
1718
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n datetime: new Date(new Date().getTime() - 1000).toJSON(),\n hash: '100e0ab6-6ff5-4199-9c04-a7107ff78712',\n media_type: 'video',\n device_state: 'playing',\n title: 'Solo: A Star Wars Story',\n artist: null,\n album: null,\n genre: null,\n total_time: 8097,\n position: 27,\n shuffle: 'off',\n repeat: 'off',\n app: 'Disney+',\n app_id: 'com.disney.disneyplus'\n });\n })\n });\n const firstResult = yield device.getState();\n assert.strictEqual(firstResult.position, 27);\n const secondResult = yield device.getState();\n assert.ok(secondResult.position);\n assert.ok(secondResult.position > 27, `Position should be > 27, was ${secondResult.position}`);\n assert.ok(secondResult.position < 30, `Position should be > 27, was ${secondResult.position}`);\n});",
1719
1719
  "err": {},
1720
- "uuid": "3229dc4a-f628-474f-9bbb-fe4fd0c495e1",
1721
- "parentUUID": "ab620283-6275-40c9-9fa5-90e7c5a2f0e3",
1720
+ "uuid": "4666033f-7713-45bd-a23b-45a381eb4e6e",
1721
+ "parentUUID": "40ef3f02-56e9-4d03-ac1d-ebc8211c4432",
1722
1722
  "isHook": false,
1723
1723
  "skipped": false
1724
1724
  }
1725
1725
  ],
1726
1726
  "suites": [],
1727
1727
  "passes": [
1728
- "72e17372-c1de-4354-84bf-e507e2c86339",
1729
- "aad79c5d-2269-4dab-8bcc-a93efe04b38d",
1730
- "7107d353-049e-4bc0-842b-9028d7fa8dab",
1731
- "3229dc4a-f628-474f-9bbb-fe4fd0c495e1"
1728
+ "e9999976-2b9f-4921-9ba0-51bcf5d7fe36",
1729
+ "3f443421-180a-42a3-b03a-961b9cd2b472",
1730
+ "74afba0a-3c48-4b76-8b6f-4b8bea6232d9",
1731
+ "4666033f-7713-45bd-a23b-45a381eb4e6e"
1732
1732
  ],
1733
1733
  "failures": [],
1734
1734
  "pending": [
1735
- "0155af3a-89b3-458e-8584-608bfdf638b2"
1735
+ "ebae24fc-62b9-45e8-a73a-31753cbb8ee0"
1736
1736
  ],
1737
1737
  "skipped": [],
1738
1738
  "duration": 6,
@@ -1741,7 +1741,7 @@
1741
1741
  "_timeout": 2000
1742
1742
  },
1743
1743
  {
1744
- "uuid": "ad46b07c-7656-4830-90b4-135f24b50253",
1744
+ "uuid": "0dd3b3dd-c4c4-415e-92de-d9d3456e106e",
1745
1745
  "title": "clearState()",
1746
1746
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1747
1747
  "file": "/test/device.ts",
@@ -1761,15 +1761,15 @@
1761
1761
  "context": null,
1762
1762
  "code": "return __awaiter(this, void 0, void 0, function* () {\n let executions = 0;\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n executions++;\n cp.end({\n result: 'success',\n datetime: '2020-11-07T22:38:43.608030+01:00',\n title: 'Solo: A Star Wars Story'\n });\n })\n });\n assert.deepStrictEqual(yield device.getTitle(), 'Solo: A Star Wars Story');\n device.clearState();\n assert.deepStrictEqual(yield device.getTitle(), 'Solo: A Star Wars Story');\n assert.strictEqual(executions, 2);\n});",
1763
1763
  "err": {},
1764
- "uuid": "3ed865be-ac38-4b2e-af16-71c160f678f6",
1765
- "parentUUID": "ad46b07c-7656-4830-90b4-135f24b50253",
1764
+ "uuid": "36d1038e-ddc0-41fc-85c8-4f733090dd90",
1765
+ "parentUUID": "0dd3b3dd-c4c4-415e-92de-d9d3456e106e",
1766
1766
  "isHook": false,
1767
1767
  "skipped": false
1768
1768
  }
1769
1769
  ],
1770
1770
  "suites": [],
1771
1771
  "passes": [
1772
- "3ed865be-ac38-4b2e-af16-71c160f678f6"
1772
+ "36d1038e-ddc0-41fc-85c8-4f733090dd90"
1773
1773
  ],
1774
1774
  "failures": [],
1775
1775
  "pending": [],
@@ -1780,7 +1780,7 @@
1780
1780
  "_timeout": 2000
1781
1781
  },
1782
1782
  {
1783
- "uuid": "1bd07896-a5f9-4624-a9e7-15d5f7fc1af6",
1783
+ "uuid": "844b3bcb-51ea-4820-b81d-978b5bf30bc1",
1784
1784
  "title": "getDateTime()",
1785
1785
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1786
1786
  "file": "/test/device.ts",
@@ -1800,15 +1800,15 @@
1800
1800
  "context": null,
1801
1801
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n datetime: new Date().toJSON()\n });\n })\n });\n const result = yield device.getDateTime();\n assert.ok(result instanceof Date);\n});",
1802
1802
  "err": {},
1803
- "uuid": "72baf9dc-089f-46b3-8ede-3912fc48a42d",
1804
- "parentUUID": "1bd07896-a5f9-4624-a9e7-15d5f7fc1af6",
1803
+ "uuid": "6ad302a4-7a03-4da7-b95e-49f4a42fcb2c",
1804
+ "parentUUID": "844b3bcb-51ea-4820-b81d-978b5bf30bc1",
1805
1805
  "isHook": false,
1806
1806
  "skipped": false
1807
1807
  }
1808
1808
  ],
1809
1809
  "suites": [],
1810
1810
  "passes": [
1811
- "72baf9dc-089f-46b3-8ede-3912fc48a42d"
1811
+ "6ad302a4-7a03-4da7-b95e-49f4a42fcb2c"
1812
1812
  ],
1813
1813
  "failures": [],
1814
1814
  "pending": [],
@@ -1819,7 +1819,7 @@
1819
1819
  "_timeout": 2000
1820
1820
  },
1821
1821
  {
1822
- "uuid": "fd7a6b91-3d29-4b6c-9a3e-37e2a679837c",
1822
+ "uuid": "810386ea-3763-4e8a-8bbe-747231a18ad5",
1823
1823
  "title": "getHash()",
1824
1824
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1825
1825
  "file": "/test/device.ts",
@@ -1830,7 +1830,7 @@
1830
1830
  "title": "should work",
1831
1831
  "fullTitle": "NodePyATVDevice getHash() should work",
1832
1832
  "timedOut": false,
1833
- "duration": 1,
1833
+ "duration": 2,
1834
1834
  "state": "passed",
1835
1835
  "speed": "fast",
1836
1836
  "pass": true,
@@ -1839,26 +1839,26 @@
1839
1839
  "context": null,
1840
1840
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n hash: '12345'\n });\n })\n });\n const result = yield device.getHash();\n assert.strictEqual(result, '12345');\n});",
1841
1841
  "err": {},
1842
- "uuid": "9ab573b6-2070-4efa-987b-c7050db7b4ae",
1843
- "parentUUID": "fd7a6b91-3d29-4b6c-9a3e-37e2a679837c",
1842
+ "uuid": "9c9ce2fc-68c0-4543-a911-374dae42bb85",
1843
+ "parentUUID": "810386ea-3763-4e8a-8bbe-747231a18ad5",
1844
1844
  "isHook": false,
1845
1845
  "skipped": false
1846
1846
  }
1847
1847
  ],
1848
1848
  "suites": [],
1849
1849
  "passes": [
1850
- "9ab573b6-2070-4efa-987b-c7050db7b4ae"
1850
+ "9c9ce2fc-68c0-4543-a911-374dae42bb85"
1851
1851
  ],
1852
1852
  "failures": [],
1853
1853
  "pending": [],
1854
1854
  "skipped": [],
1855
- "duration": 1,
1855
+ "duration": 2,
1856
1856
  "root": false,
1857
1857
  "rootEmpty": false,
1858
1858
  "_timeout": 2000
1859
1859
  },
1860
1860
  {
1861
- "uuid": "6eb87bc6-ce5d-421b-91fe-72631aae530d",
1861
+ "uuid": "a2b55691-3c08-4707-8738-883890d58361",
1862
1862
  "title": "getMediaType()",
1863
1863
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1864
1864
  "file": "/test/device.ts",
@@ -1869,7 +1869,7 @@
1869
1869
  "title": "should work",
1870
1870
  "fullTitle": "NodePyATVDevice getMediaType() should work",
1871
1871
  "timedOut": false,
1872
- "duration": 1,
1872
+ "duration": 2,
1873
1873
  "state": "passed",
1874
1874
  "speed": "fast",
1875
1875
  "pass": true,
@@ -1878,26 +1878,26 @@
1878
1878
  "context": null,
1879
1879
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n media_type: 'video'\n });\n })\n });\n const result = yield device.getMediaType();\n assert.deepStrictEqual(result, NodePyATVMediaType.video);\n assert.deepStrictEqual(result, 'video');\n});",
1880
1880
  "err": {},
1881
- "uuid": "a1c293f4-4091-48e5-90a2-dba0a843fa45",
1882
- "parentUUID": "6eb87bc6-ce5d-421b-91fe-72631aae530d",
1881
+ "uuid": "ec938218-c105-4fdc-a910-163ebfb112fe",
1882
+ "parentUUID": "a2b55691-3c08-4707-8738-883890d58361",
1883
1883
  "isHook": false,
1884
1884
  "skipped": false
1885
1885
  }
1886
1886
  ],
1887
1887
  "suites": [],
1888
1888
  "passes": [
1889
- "a1c293f4-4091-48e5-90a2-dba0a843fa45"
1889
+ "ec938218-c105-4fdc-a910-163ebfb112fe"
1890
1890
  ],
1891
1891
  "failures": [],
1892
1892
  "pending": [],
1893
1893
  "skipped": [],
1894
- "duration": 1,
1894
+ "duration": 2,
1895
1895
  "root": false,
1896
1896
  "rootEmpty": false,
1897
1897
  "_timeout": 2000
1898
1898
  },
1899
1899
  {
1900
- "uuid": "59835661-3c7d-4bc6-a51c-ea110dfa76d8",
1900
+ "uuid": "5b8c9ae7-74ee-4b77-9d52-4d0de77f0537",
1901
1901
  "title": "getDeviceState()",
1902
1902
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1903
1903
  "file": "/test/device.ts",
@@ -1908,7 +1908,7 @@
1908
1908
  "title": "should work",
1909
1909
  "fullTitle": "NodePyATVDevice getDeviceState() should work",
1910
1910
  "timedOut": false,
1911
- "duration": 1,
1911
+ "duration": 2,
1912
1912
  "state": "passed",
1913
1913
  "speed": "fast",
1914
1914
  "pass": true,
@@ -1917,26 +1917,26 @@
1917
1917
  "context": null,
1918
1918
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n device_state: 'seeking'\n });\n })\n });\n const result = yield device.getDeviceState();\n assert.deepStrictEqual(result, NodePyATVDeviceState.seeking);\n assert.deepStrictEqual(result, 'seeking');\n});",
1919
1919
  "err": {},
1920
- "uuid": "3948ed95-1ac2-42cc-a731-055130ea78a4",
1921
- "parentUUID": "59835661-3c7d-4bc6-a51c-ea110dfa76d8",
1920
+ "uuid": "b94b40dc-5304-4d59-ac72-e9efc9e445df",
1921
+ "parentUUID": "5b8c9ae7-74ee-4b77-9d52-4d0de77f0537",
1922
1922
  "isHook": false,
1923
1923
  "skipped": false
1924
1924
  }
1925
1925
  ],
1926
1926
  "suites": [],
1927
1927
  "passes": [
1928
- "3948ed95-1ac2-42cc-a731-055130ea78a4"
1928
+ "b94b40dc-5304-4d59-ac72-e9efc9e445df"
1929
1929
  ],
1930
1930
  "failures": [],
1931
1931
  "pending": [],
1932
1932
  "skipped": [],
1933
- "duration": 1,
1933
+ "duration": 2,
1934
1934
  "root": false,
1935
1935
  "rootEmpty": false,
1936
1936
  "_timeout": 2000
1937
1937
  },
1938
1938
  {
1939
- "uuid": "592cb15e-8581-47ce-8293-30b18fcb1a35",
1939
+ "uuid": "80364a26-72ac-4609-bf8a-1ed886efab01",
1940
1940
  "title": "getTitle()",
1941
1941
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1942
1942
  "file": "/test/device.ts",
@@ -1956,15 +1956,15 @@
1956
1956
  "context": null,
1957
1957
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n title: 'My Movie'\n });\n })\n });\n const result = yield device.getTitle();\n assert.strictEqual(result, 'My Movie');\n});",
1958
1958
  "err": {},
1959
- "uuid": "7ffe27ef-7cde-45b1-8ad2-1f73e115046a",
1960
- "parentUUID": "592cb15e-8581-47ce-8293-30b18fcb1a35",
1959
+ "uuid": "2d53e457-a437-4cf0-a833-bfeae7198299",
1960
+ "parentUUID": "80364a26-72ac-4609-bf8a-1ed886efab01",
1961
1961
  "isHook": false,
1962
1962
  "skipped": false
1963
1963
  }
1964
1964
  ],
1965
1965
  "suites": [],
1966
1966
  "passes": [
1967
- "7ffe27ef-7cde-45b1-8ad2-1f73e115046a"
1967
+ "2d53e457-a437-4cf0-a833-bfeae7198299"
1968
1968
  ],
1969
1969
  "failures": [],
1970
1970
  "pending": [],
@@ -1975,7 +1975,7 @@
1975
1975
  "_timeout": 2000
1976
1976
  },
1977
1977
  {
1978
- "uuid": "ec07f9af-26f2-4ce3-8281-83511bdd5c3d",
1978
+ "uuid": "a3796214-40d6-46f7-9a0c-af797a776060",
1979
1979
  "title": "getArtist()",
1980
1980
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
1981
1981
  "file": "/test/device.ts",
@@ -1995,15 +1995,15 @@
1995
1995
  "context": null,
1996
1996
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n artist: 'My Artist'\n });\n })\n });\n const result = yield device.getArtist();\n assert.strictEqual(result, 'My Artist');\n});",
1997
1997
  "err": {},
1998
- "uuid": "579dff8d-3280-4372-bf06-33aaee2f0c09",
1999
- "parentUUID": "ec07f9af-26f2-4ce3-8281-83511bdd5c3d",
1998
+ "uuid": "35bcbcd6-9275-4c9c-aca2-a822331e63a3",
1999
+ "parentUUID": "a3796214-40d6-46f7-9a0c-af797a776060",
2000
2000
  "isHook": false,
2001
2001
  "skipped": false
2002
2002
  }
2003
2003
  ],
2004
2004
  "suites": [],
2005
2005
  "passes": [
2006
- "579dff8d-3280-4372-bf06-33aaee2f0c09"
2006
+ "35bcbcd6-9275-4c9c-aca2-a822331e63a3"
2007
2007
  ],
2008
2008
  "failures": [],
2009
2009
  "pending": [],
@@ -2014,7 +2014,7 @@
2014
2014
  "_timeout": 2000
2015
2015
  },
2016
2016
  {
2017
- "uuid": "a395c200-c8a6-41d6-a297-8b571fb6de21",
2017
+ "uuid": "10d16758-0aad-449d-9d78-8e00eaf9b88a",
2018
2018
  "title": "getAlbum()",
2019
2019
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2020
2020
  "file": "/test/device.ts",
@@ -2034,15 +2034,15 @@
2034
2034
  "context": null,
2035
2035
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n album: 'My ALbum'\n });\n })\n });\n const result = yield device.getAlbum();\n assert.strictEqual(result, 'My ALbum');\n});",
2036
2036
  "err": {},
2037
- "uuid": "334847f9-c931-43e2-8630-0928b85dd5cd",
2038
- "parentUUID": "a395c200-c8a6-41d6-a297-8b571fb6de21",
2037
+ "uuid": "2b4f2060-ad39-4aa9-948c-bf54201c6e31",
2038
+ "parentUUID": "10d16758-0aad-449d-9d78-8e00eaf9b88a",
2039
2039
  "isHook": false,
2040
2040
  "skipped": false
2041
2041
  }
2042
2042
  ],
2043
2043
  "suites": [],
2044
2044
  "passes": [
2045
- "334847f9-c931-43e2-8630-0928b85dd5cd"
2045
+ "2b4f2060-ad39-4aa9-948c-bf54201c6e31"
2046
2046
  ],
2047
2047
  "failures": [],
2048
2048
  "pending": [],
@@ -2053,7 +2053,7 @@
2053
2053
  "_timeout": 2000
2054
2054
  },
2055
2055
  {
2056
- "uuid": "dd6a1662-6f1a-4d98-90c8-4d0632f59b1e",
2056
+ "uuid": "f215740b-456b-499d-b914-a5ed2284930f",
2057
2057
  "title": "getGenre()",
2058
2058
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2059
2059
  "file": "/test/device.ts",
@@ -2073,15 +2073,15 @@
2073
2073
  "context": null,
2074
2074
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n genre: 'My Genre'\n });\n })\n });\n const result = yield device.getGenre();\n assert.strictEqual(result, 'My Genre');\n});",
2075
2075
  "err": {},
2076
- "uuid": "57379a36-c3c1-4c78-bfcf-d4f5d4b6e13a",
2077
- "parentUUID": "dd6a1662-6f1a-4d98-90c8-4d0632f59b1e",
2076
+ "uuid": "685e735c-87c1-43d1-b734-14b436ba2844",
2077
+ "parentUUID": "f215740b-456b-499d-b914-a5ed2284930f",
2078
2078
  "isHook": false,
2079
2079
  "skipped": false
2080
2080
  }
2081
2081
  ],
2082
2082
  "suites": [],
2083
2083
  "passes": [
2084
- "57379a36-c3c1-4c78-bfcf-d4f5d4b6e13a"
2084
+ "685e735c-87c1-43d1-b734-14b436ba2844"
2085
2085
  ],
2086
2086
  "failures": [],
2087
2087
  "pending": [],
@@ -2092,7 +2092,7 @@
2092
2092
  "_timeout": 2000
2093
2093
  },
2094
2094
  {
2095
- "uuid": "9a84b823-a0e8-41fc-9b51-38b1e4017c3e",
2095
+ "uuid": "76d77690-ec5d-41cf-b7fe-9cb880f23e82",
2096
2096
  "title": "getTotalTime()",
2097
2097
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2098
2098
  "file": "/test/device.ts",
@@ -2103,7 +2103,7 @@
2103
2103
  "title": "should work",
2104
2104
  "fullTitle": "NodePyATVDevice getTotalTime() should work",
2105
2105
  "timedOut": false,
2106
- "duration": 1,
2106
+ "duration": 2,
2107
2107
  "state": "passed",
2108
2108
  "speed": "fast",
2109
2109
  "pass": true,
@@ -2112,26 +2112,26 @@
2112
2112
  "context": null,
2113
2113
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n total_time: 45\n });\n })\n });\n const result = yield device.getTotalTime();\n assert.strictEqual(result, 45);\n});",
2114
2114
  "err": {},
2115
- "uuid": "4c5bbede-8bcf-4412-a457-08e633b25cf6",
2116
- "parentUUID": "9a84b823-a0e8-41fc-9b51-38b1e4017c3e",
2115
+ "uuid": "1dc9f759-4ef5-40fb-8185-05c594c2f027",
2116
+ "parentUUID": "76d77690-ec5d-41cf-b7fe-9cb880f23e82",
2117
2117
  "isHook": false,
2118
2118
  "skipped": false
2119
2119
  }
2120
2120
  ],
2121
2121
  "suites": [],
2122
2122
  "passes": [
2123
- "4c5bbede-8bcf-4412-a457-08e633b25cf6"
2123
+ "1dc9f759-4ef5-40fb-8185-05c594c2f027"
2124
2124
  ],
2125
2125
  "failures": [],
2126
2126
  "pending": [],
2127
2127
  "skipped": [],
2128
- "duration": 1,
2128
+ "duration": 2,
2129
2129
  "root": false,
2130
2130
  "rootEmpty": false,
2131
2131
  "_timeout": 2000
2132
2132
  },
2133
2133
  {
2134
- "uuid": "e7b2ab89-8f1a-416e-a400-4ac061fdd3f9",
2134
+ "uuid": "82044487-6b2d-4922-9675-06f5aa1a4e7a",
2135
2135
  "title": "getPosition()",
2136
2136
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2137
2137
  "file": "/test/device.ts",
@@ -2151,15 +2151,15 @@
2151
2151
  "context": null,
2152
2152
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n position: 30\n });\n })\n });\n const result = yield device.getPosition();\n assert.strictEqual(result, 30);\n});",
2153
2153
  "err": {},
2154
- "uuid": "2975b5aa-61dd-4663-b9d1-54b59981d89b",
2155
- "parentUUID": "e7b2ab89-8f1a-416e-a400-4ac061fdd3f9",
2154
+ "uuid": "96641967-b444-430b-8227-3e002a143c16",
2155
+ "parentUUID": "82044487-6b2d-4922-9675-06f5aa1a4e7a",
2156
2156
  "isHook": false,
2157
2157
  "skipped": false
2158
2158
  }
2159
2159
  ],
2160
2160
  "suites": [],
2161
2161
  "passes": [
2162
- "2975b5aa-61dd-4663-b9d1-54b59981d89b"
2162
+ "96641967-b444-430b-8227-3e002a143c16"
2163
2163
  ],
2164
2164
  "failures": [],
2165
2165
  "pending": [],
@@ -2170,7 +2170,7 @@
2170
2170
  "_timeout": 2000
2171
2171
  },
2172
2172
  {
2173
- "uuid": "e7e343ee-0eae-457b-a1c4-dfc775f2d110",
2173
+ "uuid": "663e64d6-58bb-40b3-97fe-13e4e32a3e62",
2174
2174
  "title": "getShuffle()",
2175
2175
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2176
2176
  "file": "/test/device.ts",
@@ -2190,15 +2190,15 @@
2190
2190
  "context": null,
2191
2191
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n shuffle: 'songs'\n });\n })\n });\n const result = yield device.getShuffle();\n assert.deepStrictEqual(result, NodePyATVShuffleState.songs);\n assert.deepStrictEqual(result, 'songs');\n});",
2192
2192
  "err": {},
2193
- "uuid": "58227c6a-c107-41c8-a674-4c5ba593dbfe",
2194
- "parentUUID": "e7e343ee-0eae-457b-a1c4-dfc775f2d110",
2193
+ "uuid": "22972b7b-1b2f-4348-ba9d-1ad99e1cdf14",
2194
+ "parentUUID": "663e64d6-58bb-40b3-97fe-13e4e32a3e62",
2195
2195
  "isHook": false,
2196
2196
  "skipped": false
2197
2197
  }
2198
2198
  ],
2199
2199
  "suites": [],
2200
2200
  "passes": [
2201
- "58227c6a-c107-41c8-a674-4c5ba593dbfe"
2201
+ "22972b7b-1b2f-4348-ba9d-1ad99e1cdf14"
2202
2202
  ],
2203
2203
  "failures": [],
2204
2204
  "pending": [],
@@ -2209,7 +2209,7 @@
2209
2209
  "_timeout": 2000
2210
2210
  },
2211
2211
  {
2212
- "uuid": "abfa272f-0c77-4f04-a004-20803d40679d",
2212
+ "uuid": "ff40de55-cc4f-4223-a4e1-09a743276b1a",
2213
2213
  "title": "getRepeat()",
2214
2214
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2215
2215
  "file": "/test/device.ts",
@@ -2229,15 +2229,15 @@
2229
2229
  "context": null,
2230
2230
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n repeat: 'all'\n });\n })\n });\n const result = yield device.getRepeat();\n assert.deepStrictEqual(result, NodePyATVRepeatState.all);\n assert.deepStrictEqual(result, 'all');\n});",
2231
2231
  "err": {},
2232
- "uuid": "ff2b8d22-f46e-442d-aacf-cbec960e10dc",
2233
- "parentUUID": "abfa272f-0c77-4f04-a004-20803d40679d",
2232
+ "uuid": "7bcd1d07-bedb-478a-8a59-86970c38cfc3",
2233
+ "parentUUID": "ff40de55-cc4f-4223-a4e1-09a743276b1a",
2234
2234
  "isHook": false,
2235
2235
  "skipped": false
2236
2236
  }
2237
2237
  ],
2238
2238
  "suites": [],
2239
2239
  "passes": [
2240
- "ff2b8d22-f46e-442d-aacf-cbec960e10dc"
2240
+ "7bcd1d07-bedb-478a-8a59-86970c38cfc3"
2241
2241
  ],
2242
2242
  "failures": [],
2243
2243
  "pending": [],
@@ -2248,7 +2248,7 @@
2248
2248
  "_timeout": 2000
2249
2249
  },
2250
2250
  {
2251
- "uuid": "11ca3509-020b-4f09-9601-8dd31fb599b5",
2251
+ "uuid": "ab23dede-5c6e-4b80-a88a-10ab877c7727",
2252
2252
  "title": "getApp()",
2253
2253
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2254
2254
  "file": "/test/device.ts",
@@ -2259,7 +2259,7 @@
2259
2259
  "title": "should work",
2260
2260
  "fullTitle": "NodePyATVDevice getApp() should work",
2261
2261
  "timedOut": false,
2262
- "duration": 2,
2262
+ "duration": 1,
2263
2263
  "state": "passed",
2264
2264
  "speed": "fast",
2265
2265
  "pass": true,
@@ -2268,26 +2268,26 @@
2268
2268
  "context": null,
2269
2269
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n app: 'My App'\n });\n })\n });\n const result = yield device.getApp();\n assert.strictEqual(result, 'My App');\n});",
2270
2270
  "err": {},
2271
- "uuid": "a5d3a43c-13fc-434b-86ec-ffa8d8b89efd",
2272
- "parentUUID": "11ca3509-020b-4f09-9601-8dd31fb599b5",
2271
+ "uuid": "8eae7fd8-2d9c-4d98-b5b5-682c7226c925",
2272
+ "parentUUID": "ab23dede-5c6e-4b80-a88a-10ab877c7727",
2273
2273
  "isHook": false,
2274
2274
  "skipped": false
2275
2275
  }
2276
2276
  ],
2277
2277
  "suites": [],
2278
2278
  "passes": [
2279
- "a5d3a43c-13fc-434b-86ec-ffa8d8b89efd"
2279
+ "8eae7fd8-2d9c-4d98-b5b5-682c7226c925"
2280
2280
  ],
2281
2281
  "failures": [],
2282
2282
  "pending": [],
2283
2283
  "skipped": [],
2284
- "duration": 2,
2284
+ "duration": 1,
2285
2285
  "root": false,
2286
2286
  "rootEmpty": false,
2287
2287
  "_timeout": 2000
2288
2288
  },
2289
2289
  {
2290
- "uuid": "1b81f9a7-1474-45db-9105-8b0179955791",
2290
+ "uuid": "36b42f84-47d3-4b60-93fb-942e705f00ab",
2291
2291
  "title": "getAppId()",
2292
2292
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2293
2293
  "file": "/test/device.ts",
@@ -2298,7 +2298,7 @@
2298
2298
  "title": "should work",
2299
2299
  "fullTitle": "NodePyATVDevice getAppId() should work",
2300
2300
  "timedOut": false,
2301
- "duration": 2,
2301
+ "duration": 1,
2302
2302
  "state": "passed",
2303
2303
  "speed": "fast",
2304
2304
  "pass": true,
@@ -2307,26 +2307,65 @@
2307
2307
  "context": null,
2308
2308
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end({\n result: 'success',\n app_id: 'app.example.com'\n });\n })\n });\n const result = yield device.getAppId();\n assert.strictEqual(result, 'app.example.com');\n});",
2309
2309
  "err": {},
2310
- "uuid": "13bd3f82-ad8b-4b1e-9cf9-523a6a3cb2af",
2311
- "parentUUID": "1b81f9a7-1474-45db-9105-8b0179955791",
2310
+ "uuid": "8da9a064-e563-4007-b1a0-79f063377bb5",
2311
+ "parentUUID": "36b42f84-47d3-4b60-93fb-942e705f00ab",
2312
2312
  "isHook": false,
2313
2313
  "skipped": false
2314
2314
  }
2315
2315
  ],
2316
2316
  "suites": [],
2317
2317
  "passes": [
2318
- "13bd3f82-ad8b-4b1e-9cf9-523a6a3cb2af"
2318
+ "8da9a064-e563-4007-b1a0-79f063377bb5"
2319
2319
  ],
2320
2320
  "failures": [],
2321
2321
  "pending": [],
2322
2322
  "skipped": [],
2323
- "duration": 2,
2323
+ "duration": 1,
2324
2324
  "root": false,
2325
2325
  "rootEmpty": false,
2326
2326
  "_timeout": 2000
2327
2327
  },
2328
2328
  {
2329
- "uuid": "baf4a1b4-9761-46b2-96dc-b871438a7364",
2329
+ "uuid": "77a63472-cf2b-4137-81e1-3a5781b148b1",
2330
+ "title": "listApps()",
2331
+ "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2332
+ "file": "/test/device.ts",
2333
+ "beforeHooks": [],
2334
+ "afterHooks": [],
2335
+ "tests": [
2336
+ {
2337
+ "title": "should work",
2338
+ "fullTitle": "NodePyATVDevice listApps() should work",
2339
+ "timedOut": false,
2340
+ "duration": 0,
2341
+ "state": "passed",
2342
+ "speed": "fast",
2343
+ "pass": true,
2344
+ "fail": false,
2345
+ "pending": false,
2346
+ "context": null,
2347
+ "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('App: Fitness (com.apple.Fitness), App: Podcasts (com.apple.podcasts), ' +\n 'App: Filme (com.apple.TVMovies), App: Prime Video (com.amazon.aiv.AIVApp), ' +\n 'App: TV (com.apple.TVWatchList), App: Fotos (com.apple.TVPhotos), App: App Store ' +\n '(com.apple.TVAppStore), App: Arcade (com.apple.Arcade), App: TV-Sendungen (com.apple.TVShows), ' +\n 'App: Suchen (com.apple.TVSearch), App: Live TV (de.couchfunk.WM2014), App: RTL+ ' +\n '(com.rtlinteractive.tvnow), App: Computer (com.apple.TVHomeSharing), App: ARTE ' +\n '(tv.arte.plus7), App: YouTube (com.google.ios.youtube), App: ARD Mediathek ' +\n '(de.swr.avp.ard.tablet), App: Disney+ (com.disney.disneyplus), App: Plex (com.plexapp.plex), ' +\n 'App: Joyn (de.prosiebensat1digital.seventv), App: Einstellungen (com.apple.TVSettings), ' +\n 'App: ZDFmediathek (de.zdf.mediathek.universal), App: Crossy Road (com.hipsterwhale.crossy), ' +\n 'App: Netflix (com.netflix.Netflix), App: Infuse (com.firecore.infuse), ' +\n 'App: Musik (com.apple.TVMusic)');\n })\n });\n const result = yield device.listApps();\n assert.strictEqual(result.length, 25);\n assert.strictEqual(result[0].id, 'com.apple.Fitness');\n assert.strictEqual(result[0].name, 'Fitness');\n});",
2348
+ "err": {},
2349
+ "uuid": "d4a70ac6-cb61-460a-93a7-0afcab2ebe6f",
2350
+ "parentUUID": "77a63472-cf2b-4137-81e1-3a5781b148b1",
2351
+ "isHook": false,
2352
+ "skipped": false
2353
+ }
2354
+ ],
2355
+ "suites": [],
2356
+ "passes": [
2357
+ "d4a70ac6-cb61-460a-93a7-0afcab2ebe6f"
2358
+ ],
2359
+ "failures": [],
2360
+ "pending": [],
2361
+ "skipped": [],
2362
+ "duration": 0,
2363
+ "root": false,
2364
+ "rootEmpty": false,
2365
+ "_timeout": 2000
2366
+ },
2367
+ {
2368
+ "uuid": "26d9ef6b-71a4-47a5-9721-ee76740df50d",
2330
2369
  "title": "pressKey()",
2331
2370
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2332
2371
  "file": "/test/device.ts",
@@ -2337,7 +2376,7 @@
2337
2376
  "title": "should work with valid key",
2338
2377
  "fullTitle": "NodePyATVDevice pressKey() should work with valid key",
2339
2378
  "timedOut": false,
2340
- "duration": 3,
2379
+ "duration": 2,
2341
2380
  "state": "passed",
2342
2381
  "speed": "fast",
2343
2382
  "pass": true,
@@ -2346,8 +2385,8 @@
2346
2385
  "context": null,
2347
2386
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n yield device.pressKey(NodePyATVKeys.home);\n});",
2348
2387
  "err": {},
2349
- "uuid": "c85f9112-4e97-4e7b-bc20-729dd9bf5ec6",
2350
- "parentUUID": "baf4a1b4-9761-46b2-96dc-b871438a7364",
2388
+ "uuid": "cf32cd4e-7f02-4cc1-b1b8-4e16313197e3",
2389
+ "parentUUID": "26d9ef6b-71a4-47a5-9721-ee76740df50d",
2351
2390
  "isHook": false,
2352
2391
  "skipped": false
2353
2392
  },
@@ -2355,7 +2394,7 @@
2355
2394
  "title": "should throw error with invalid key",
2356
2395
  "fullTitle": "NodePyATVDevice pressKey() should throw error with invalid key",
2357
2396
  "timedOut": false,
2358
- "duration": 1,
2397
+ "duration": 0,
2359
2398
  "state": "passed",
2360
2399
  "speed": "fast",
2361
2400
  "pass": true,
@@ -2364,8 +2403,8 @@
2364
2403
  "context": null,
2365
2404
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2'\n });\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n // @ts-ignore\n yield device.pressKey('foo');\n }), /Unsupported key value foo/);\n});",
2366
2405
  "err": {},
2367
- "uuid": "d14ad488-78cc-4219-84a6-d36c2c4f1f7a",
2368
- "parentUUID": "baf4a1b4-9761-46b2-96dc-b871438a7364",
2406
+ "uuid": "ea691134-7c7e-45f7-a6a5-64a8b50bfb2a",
2407
+ "parentUUID": "26d9ef6b-71a4-47a5-9721-ee76740df50d",
2369
2408
  "isHook": false,
2370
2409
  "skipped": false
2371
2410
  },
@@ -2373,7 +2412,7 @@
2373
2412
  "title": "should throw error if pyatv result is not success",
2374
2413
  "fullTitle": "NodePyATVDevice pressKey() should throw error if pyatv result is not success",
2375
2414
  "timedOut": false,
2376
- "duration": 1,
2415
+ "duration": 2,
2377
2416
  "state": "passed",
2378
2417
  "speed": "fast",
2379
2418
  "pass": true,
@@ -2382,28 +2421,28 @@
2382
2421
  "context": null,
2383
2422
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"failure\"}');\n })\n });\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield device.pressKey(NodePyATVKeys.home);\n }), /Unable to parse pyatv response/);\n});",
2384
2423
  "err": {},
2385
- "uuid": "664ee434-2d7d-49f4-ac0a-4a944ad5fef7",
2386
- "parentUUID": "baf4a1b4-9761-46b2-96dc-b871438a7364",
2424
+ "uuid": "4ee5682d-ecd6-428d-b494-a5a47ba011e8",
2425
+ "parentUUID": "26d9ef6b-71a4-47a5-9721-ee76740df50d",
2387
2426
  "isHook": false,
2388
2427
  "skipped": false
2389
2428
  }
2390
2429
  ],
2391
2430
  "suites": [],
2392
2431
  "passes": [
2393
- "c85f9112-4e97-4e7b-bc20-729dd9bf5ec6",
2394
- "d14ad488-78cc-4219-84a6-d36c2c4f1f7a",
2395
- "664ee434-2d7d-49f4-ac0a-4a944ad5fef7"
2432
+ "cf32cd4e-7f02-4cc1-b1b8-4e16313197e3",
2433
+ "ea691134-7c7e-45f7-a6a5-64a8b50bfb2a",
2434
+ "4ee5682d-ecd6-428d-b494-a5a47ba011e8"
2396
2435
  ],
2397
2436
  "failures": [],
2398
2437
  "pending": [],
2399
2438
  "skipped": [],
2400
- "duration": 5,
2439
+ "duration": 4,
2401
2440
  "root": false,
2402
2441
  "rootEmpty": false,
2403
2442
  "_timeout": 2000
2404
2443
  },
2405
2444
  {
2406
- "uuid": "2d86e8db-285b-4100-9d2e-51daac15348f",
2445
+ "uuid": "8130a82a-f8d2-48db-af02-b1c7b67e41a9",
2407
2446
  "title": "down()",
2408
2447
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2409
2448
  "file": "/test/device.ts",
@@ -2423,15 +2462,15 @@
2423
2462
  "context": null,
2424
2463
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2425
2464
  "err": {},
2426
- "uuid": "9e6e5c7f-2149-4896-891d-d1c80e2852f8",
2427
- "parentUUID": "2d86e8db-285b-4100-9d2e-51daac15348f",
2465
+ "uuid": "4ee2bc3b-bf4d-4b4a-9b6b-98e9eb6a1491",
2466
+ "parentUUID": "8130a82a-f8d2-48db-af02-b1c7b67e41a9",
2428
2467
  "isHook": false,
2429
2468
  "skipped": false
2430
2469
  }
2431
2470
  ],
2432
2471
  "suites": [],
2433
2472
  "passes": [
2434
- "9e6e5c7f-2149-4896-891d-d1c80e2852f8"
2473
+ "4ee2bc3b-bf4d-4b4a-9b6b-98e9eb6a1491"
2435
2474
  ],
2436
2475
  "failures": [],
2437
2476
  "pending": [],
@@ -2442,7 +2481,7 @@
2442
2481
  "_timeout": 2000
2443
2482
  },
2444
2483
  {
2445
- "uuid": "7a570f9c-6ef2-4f1c-a629-fc2396e16085",
2484
+ "uuid": "a394aa85-6c17-41db-bb6a-08ca7e09e68c",
2446
2485
  "title": "home()",
2447
2486
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2448
2487
  "file": "/test/device.ts",
@@ -2462,15 +2501,15 @@
2462
2501
  "context": null,
2463
2502
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2464
2503
  "err": {},
2465
- "uuid": "dc52cfec-29ce-4434-9d36-1067715e9648",
2466
- "parentUUID": "7a570f9c-6ef2-4f1c-a629-fc2396e16085",
2504
+ "uuid": "2ff8214f-6202-4360-924d-7969f5db685f",
2505
+ "parentUUID": "a394aa85-6c17-41db-bb6a-08ca7e09e68c",
2467
2506
  "isHook": false,
2468
2507
  "skipped": false
2469
2508
  }
2470
2509
  ],
2471
2510
  "suites": [],
2472
2511
  "passes": [
2473
- "dc52cfec-29ce-4434-9d36-1067715e9648"
2512
+ "2ff8214f-6202-4360-924d-7969f5db685f"
2474
2513
  ],
2475
2514
  "failures": [],
2476
2515
  "pending": [],
@@ -2481,7 +2520,7 @@
2481
2520
  "_timeout": 2000
2482
2521
  },
2483
2522
  {
2484
- "uuid": "22425b13-ff51-48cb-b0fa-e9f6875f7104",
2523
+ "uuid": "400c2b0d-7471-4607-85d8-faaa1c2c51a7",
2485
2524
  "title": "homeHold()",
2486
2525
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2487
2526
  "file": "/test/device.ts",
@@ -2492,7 +2531,7 @@
2492
2531
  "title": "should work",
2493
2532
  "fullTitle": "NodePyATVDevice homeHold() should work",
2494
2533
  "timedOut": false,
2495
- "duration": 2,
2534
+ "duration": 1,
2496
2535
  "state": "passed",
2497
2536
  "speed": "fast",
2498
2537
  "pass": true,
@@ -2501,26 +2540,26 @@
2501
2540
  "context": null,
2502
2541
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2503
2542
  "err": {},
2504
- "uuid": "8424fb25-f08c-4781-b596-7c120d5852c6",
2505
- "parentUUID": "22425b13-ff51-48cb-b0fa-e9f6875f7104",
2543
+ "uuid": "722e663a-33a6-4974-808a-74b549963a72",
2544
+ "parentUUID": "400c2b0d-7471-4607-85d8-faaa1c2c51a7",
2506
2545
  "isHook": false,
2507
2546
  "skipped": false
2508
2547
  }
2509
2548
  ],
2510
2549
  "suites": [],
2511
2550
  "passes": [
2512
- "8424fb25-f08c-4781-b596-7c120d5852c6"
2551
+ "722e663a-33a6-4974-808a-74b549963a72"
2513
2552
  ],
2514
2553
  "failures": [],
2515
2554
  "pending": [],
2516
2555
  "skipped": [],
2517
- "duration": 2,
2556
+ "duration": 1,
2518
2557
  "root": false,
2519
2558
  "rootEmpty": false,
2520
2559
  "_timeout": 2000
2521
2560
  },
2522
2561
  {
2523
- "uuid": "37a27d42-3d1b-4d58-86c4-eecd9fd1fee0",
2562
+ "uuid": "2f552f8e-2a2b-45e4-8c0e-80ccdc846ba3",
2524
2563
  "title": "left()",
2525
2564
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2526
2565
  "file": "/test/device.ts",
@@ -2531,7 +2570,7 @@
2531
2570
  "title": "should work",
2532
2571
  "fullTitle": "NodePyATVDevice left() should work",
2533
2572
  "timedOut": false,
2534
- "duration": 1,
2573
+ "duration": 2,
2535
2574
  "state": "passed",
2536
2575
  "speed": "fast",
2537
2576
  "pass": true,
@@ -2540,26 +2579,26 @@
2540
2579
  "context": null,
2541
2580
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2542
2581
  "err": {},
2543
- "uuid": "320854a8-388a-44af-bb58-6cc9ca9278d7",
2544
- "parentUUID": "37a27d42-3d1b-4d58-86c4-eecd9fd1fee0",
2582
+ "uuid": "97b85bc1-964d-4b49-92f1-daa8f18ae15c",
2583
+ "parentUUID": "2f552f8e-2a2b-45e4-8c0e-80ccdc846ba3",
2545
2584
  "isHook": false,
2546
2585
  "skipped": false
2547
2586
  }
2548
2587
  ],
2549
2588
  "suites": [],
2550
2589
  "passes": [
2551
- "320854a8-388a-44af-bb58-6cc9ca9278d7"
2590
+ "97b85bc1-964d-4b49-92f1-daa8f18ae15c"
2552
2591
  ],
2553
2592
  "failures": [],
2554
2593
  "pending": [],
2555
2594
  "skipped": [],
2556
- "duration": 1,
2595
+ "duration": 2,
2557
2596
  "root": false,
2558
2597
  "rootEmpty": false,
2559
2598
  "_timeout": 2000
2560
2599
  },
2561
2600
  {
2562
- "uuid": "dc13c74e-a2d7-4fef-940d-7509fb659f33",
2601
+ "uuid": "1737fb18-4fae-41bf-96c5-3d3c1da41fb6",
2563
2602
  "title": "menu()",
2564
2603
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2565
2604
  "file": "/test/device.ts",
@@ -2579,15 +2618,15 @@
2579
2618
  "context": null,
2580
2619
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2581
2620
  "err": {},
2582
- "uuid": "e9f749bf-3a96-41d1-a02d-cdc5736baccd",
2583
- "parentUUID": "dc13c74e-a2d7-4fef-940d-7509fb659f33",
2621
+ "uuid": "1ded3d63-ff54-48e9-9767-342df037c88c",
2622
+ "parentUUID": "1737fb18-4fae-41bf-96c5-3d3c1da41fb6",
2584
2623
  "isHook": false,
2585
2624
  "skipped": false
2586
2625
  }
2587
2626
  ],
2588
2627
  "suites": [],
2589
2628
  "passes": [
2590
- "e9f749bf-3a96-41d1-a02d-cdc5736baccd"
2629
+ "1ded3d63-ff54-48e9-9767-342df037c88c"
2591
2630
  ],
2592
2631
  "failures": [],
2593
2632
  "pending": [],
@@ -2598,7 +2637,7 @@
2598
2637
  "_timeout": 2000
2599
2638
  },
2600
2639
  {
2601
- "uuid": "8c4c00b0-4dc0-426e-99b5-0cb162bcafc2",
2640
+ "uuid": "22bf55ca-be90-45fa-8be3-27f7a353f7c3",
2602
2641
  "title": "next()",
2603
2642
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2604
2643
  "file": "/test/device.ts",
@@ -2618,15 +2657,15 @@
2618
2657
  "context": null,
2619
2658
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2620
2659
  "err": {},
2621
- "uuid": "525f1b28-389e-4610-a4a8-c9386cc7d33a",
2622
- "parentUUID": "8c4c00b0-4dc0-426e-99b5-0cb162bcafc2",
2660
+ "uuid": "1e6b3943-ce13-4d50-97a8-c4c1f9b66a51",
2661
+ "parentUUID": "22bf55ca-be90-45fa-8be3-27f7a353f7c3",
2623
2662
  "isHook": false,
2624
2663
  "skipped": false
2625
2664
  }
2626
2665
  ],
2627
2666
  "suites": [],
2628
2667
  "passes": [
2629
- "525f1b28-389e-4610-a4a8-c9386cc7d33a"
2668
+ "1e6b3943-ce13-4d50-97a8-c4c1f9b66a51"
2630
2669
  ],
2631
2670
  "failures": [],
2632
2671
  "pending": [],
@@ -2637,7 +2676,7 @@
2637
2676
  "_timeout": 2000
2638
2677
  },
2639
2678
  {
2640
- "uuid": "fa4840c9-01f4-42f3-9dae-3fcdf00554fd",
2679
+ "uuid": "d429dd42-fd21-4fe3-9296-ef955ab8a076",
2641
2680
  "title": "pause()",
2642
2681
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2643
2682
  "file": "/test/device.ts",
@@ -2657,15 +2696,15 @@
2657
2696
  "context": null,
2658
2697
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2659
2698
  "err": {},
2660
- "uuid": "4063cd8c-42b8-482d-9ec9-b00b71d1b534",
2661
- "parentUUID": "fa4840c9-01f4-42f3-9dae-3fcdf00554fd",
2699
+ "uuid": "1ec61d4f-5c21-4b66-a142-ee16cdcf2fe3",
2700
+ "parentUUID": "d429dd42-fd21-4fe3-9296-ef955ab8a076",
2662
2701
  "isHook": false,
2663
2702
  "skipped": false
2664
2703
  }
2665
2704
  ],
2666
2705
  "suites": [],
2667
2706
  "passes": [
2668
- "4063cd8c-42b8-482d-9ec9-b00b71d1b534"
2707
+ "1ec61d4f-5c21-4b66-a142-ee16cdcf2fe3"
2669
2708
  ],
2670
2709
  "failures": [],
2671
2710
  "pending": [],
@@ -2676,7 +2715,7 @@
2676
2715
  "_timeout": 2000
2677
2716
  },
2678
2717
  {
2679
- "uuid": "95712fab-e068-477b-9c19-504694f1b57a",
2718
+ "uuid": "daf52f11-fff0-4574-b3fa-d992ff50fb2e",
2680
2719
  "title": "play()",
2681
2720
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2682
2721
  "file": "/test/device.ts",
@@ -2687,7 +2726,7 @@
2687
2726
  "title": "should work",
2688
2727
  "fullTitle": "NodePyATVDevice play() should work",
2689
2728
  "timedOut": false,
2690
- "duration": 2,
2729
+ "duration": 1,
2691
2730
  "state": "passed",
2692
2731
  "speed": "fast",
2693
2732
  "pass": true,
@@ -2696,26 +2735,26 @@
2696
2735
  "context": null,
2697
2736
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2698
2737
  "err": {},
2699
- "uuid": "0b88bb5d-30e3-4913-8e6c-a792e1c0ef7d",
2700
- "parentUUID": "95712fab-e068-477b-9c19-504694f1b57a",
2738
+ "uuid": "0a3aaaf7-4538-4eb9-925e-08a3e1d5e97b",
2739
+ "parentUUID": "daf52f11-fff0-4574-b3fa-d992ff50fb2e",
2701
2740
  "isHook": false,
2702
2741
  "skipped": false
2703
2742
  }
2704
2743
  ],
2705
2744
  "suites": [],
2706
2745
  "passes": [
2707
- "0b88bb5d-30e3-4913-8e6c-a792e1c0ef7d"
2746
+ "0a3aaaf7-4538-4eb9-925e-08a3e1d5e97b"
2708
2747
  ],
2709
2748
  "failures": [],
2710
2749
  "pending": [],
2711
2750
  "skipped": [],
2712
- "duration": 2,
2751
+ "duration": 1,
2713
2752
  "root": false,
2714
2753
  "rootEmpty": false,
2715
2754
  "_timeout": 2000
2716
2755
  },
2717
2756
  {
2718
- "uuid": "4fd6cffa-bd16-49d9-b543-f7cfb0eb7d7a",
2757
+ "uuid": "b7b5afbb-2235-42d2-8485-b72f7314be7f",
2719
2758
  "title": "playPause()",
2720
2759
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2721
2760
  "file": "/test/device.ts",
@@ -2726,7 +2765,7 @@
2726
2765
  "title": "should work",
2727
2766
  "fullTitle": "NodePyATVDevice playPause() should work",
2728
2767
  "timedOut": false,
2729
- "duration": 2,
2768
+ "duration": 1,
2730
2769
  "state": "passed",
2731
2770
  "speed": "fast",
2732
2771
  "pass": true,
@@ -2735,26 +2774,26 @@
2735
2774
  "context": null,
2736
2775
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2737
2776
  "err": {},
2738
- "uuid": "cf7c42c9-b3cf-4cf5-aef0-9b356b4107b8",
2739
- "parentUUID": "4fd6cffa-bd16-49d9-b543-f7cfb0eb7d7a",
2777
+ "uuid": "6916e08f-3626-4fa4-ad74-dc433dce20e0",
2778
+ "parentUUID": "b7b5afbb-2235-42d2-8485-b72f7314be7f",
2740
2779
  "isHook": false,
2741
2780
  "skipped": false
2742
2781
  }
2743
2782
  ],
2744
2783
  "suites": [],
2745
2784
  "passes": [
2746
- "cf7c42c9-b3cf-4cf5-aef0-9b356b4107b8"
2785
+ "6916e08f-3626-4fa4-ad74-dc433dce20e0"
2747
2786
  ],
2748
2787
  "failures": [],
2749
2788
  "pending": [],
2750
2789
  "skipped": [],
2751
- "duration": 2,
2790
+ "duration": 1,
2752
2791
  "root": false,
2753
2792
  "rootEmpty": false,
2754
2793
  "_timeout": 2000
2755
2794
  },
2756
2795
  {
2757
- "uuid": "cb82adc4-fe04-4d79-bd3b-82472710c71a",
2796
+ "uuid": "b1ed2922-670a-4231-bfca-fd204dca7794",
2758
2797
  "title": "previous()",
2759
2798
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2760
2799
  "file": "/test/device.ts",
@@ -2765,7 +2804,7 @@
2765
2804
  "title": "should work",
2766
2805
  "fullTitle": "NodePyATVDevice previous() should work",
2767
2806
  "timedOut": false,
2768
- "duration": 1,
2807
+ "duration": 2,
2769
2808
  "state": "passed",
2770
2809
  "speed": "fast",
2771
2810
  "pass": true,
@@ -2774,26 +2813,26 @@
2774
2813
  "context": null,
2775
2814
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2776
2815
  "err": {},
2777
- "uuid": "99154386-fca5-4a89-9a1b-b7782ee10fbf",
2778
- "parentUUID": "cb82adc4-fe04-4d79-bd3b-82472710c71a",
2816
+ "uuid": "efc3f43c-05a4-48a7-9c34-45b56af57529",
2817
+ "parentUUID": "b1ed2922-670a-4231-bfca-fd204dca7794",
2779
2818
  "isHook": false,
2780
2819
  "skipped": false
2781
2820
  }
2782
2821
  ],
2783
2822
  "suites": [],
2784
2823
  "passes": [
2785
- "99154386-fca5-4a89-9a1b-b7782ee10fbf"
2824
+ "efc3f43c-05a4-48a7-9c34-45b56af57529"
2786
2825
  ],
2787
2826
  "failures": [],
2788
2827
  "pending": [],
2789
2828
  "skipped": [],
2790
- "duration": 1,
2829
+ "duration": 2,
2791
2830
  "root": false,
2792
2831
  "rootEmpty": false,
2793
2832
  "_timeout": 2000
2794
2833
  },
2795
2834
  {
2796
- "uuid": "e157df09-2dc8-4605-9aec-25d20cfcd61f",
2835
+ "uuid": "679eb54d-11c8-41a5-86e6-4a78d8e1df1e",
2797
2836
  "title": "right()",
2798
2837
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2799
2838
  "file": "/test/device.ts",
@@ -2813,15 +2852,15 @@
2813
2852
  "context": null,
2814
2853
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2815
2854
  "err": {},
2816
- "uuid": "5077a67c-ffb2-4d50-8b4d-7cbffeac0173",
2817
- "parentUUID": "e157df09-2dc8-4605-9aec-25d20cfcd61f",
2855
+ "uuid": "8344e398-de9c-42c0-a609-f9417ae86ef3",
2856
+ "parentUUID": "679eb54d-11c8-41a5-86e6-4a78d8e1df1e",
2818
2857
  "isHook": false,
2819
2858
  "skipped": false
2820
2859
  }
2821
2860
  ],
2822
2861
  "suites": [],
2823
2862
  "passes": [
2824
- "5077a67c-ffb2-4d50-8b4d-7cbffeac0173"
2863
+ "8344e398-de9c-42c0-a609-f9417ae86ef3"
2825
2864
  ],
2826
2865
  "failures": [],
2827
2866
  "pending": [],
@@ -2832,7 +2871,7 @@
2832
2871
  "_timeout": 2000
2833
2872
  },
2834
2873
  {
2835
- "uuid": "0fb92cc6-be4d-4878-9964-024c42f70a98",
2874
+ "uuid": "ae983f5c-6eeb-4a41-be88-3c63c305ceb3",
2836
2875
  "title": "select()",
2837
2876
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2838
2877
  "file": "/test/device.ts",
@@ -2852,15 +2891,15 @@
2852
2891
  "context": null,
2853
2892
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2854
2893
  "err": {},
2855
- "uuid": "a0ddf843-aa3f-4675-8c8d-f0bc810a50b2",
2856
- "parentUUID": "0fb92cc6-be4d-4878-9964-024c42f70a98",
2894
+ "uuid": "539ba48e-93f1-49aa-b66e-97f2a7e33f28",
2895
+ "parentUUID": "ae983f5c-6eeb-4a41-be88-3c63c305ceb3",
2857
2896
  "isHook": false,
2858
2897
  "skipped": false
2859
2898
  }
2860
2899
  ],
2861
2900
  "suites": [],
2862
2901
  "passes": [
2863
- "a0ddf843-aa3f-4675-8c8d-f0bc810a50b2"
2902
+ "539ba48e-93f1-49aa-b66e-97f2a7e33f28"
2864
2903
  ],
2865
2904
  "failures": [],
2866
2905
  "pending": [],
@@ -2871,7 +2910,7 @@
2871
2910
  "_timeout": 2000
2872
2911
  },
2873
2912
  {
2874
- "uuid": "209e69ac-7632-42ce-b147-367d37e0e9cd",
2913
+ "uuid": "9efd553b-8ecb-4839-85b4-ed278bf442f5",
2875
2914
  "title": "skipBackward()",
2876
2915
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2877
2916
  "file": "/test/device.ts",
@@ -2891,15 +2930,15 @@
2891
2930
  "context": null,
2892
2931
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2893
2932
  "err": {},
2894
- "uuid": "22fd7d3b-e34a-4082-85c1-a0aa9f22f4bf",
2895
- "parentUUID": "209e69ac-7632-42ce-b147-367d37e0e9cd",
2933
+ "uuid": "fc2c6bbe-f61b-4ab3-bd28-e0fd4930058b",
2934
+ "parentUUID": "9efd553b-8ecb-4839-85b4-ed278bf442f5",
2896
2935
  "isHook": false,
2897
2936
  "skipped": false
2898
2937
  }
2899
2938
  ],
2900
2939
  "suites": [],
2901
2940
  "passes": [
2902
- "22fd7d3b-e34a-4082-85c1-a0aa9f22f4bf"
2941
+ "fc2c6bbe-f61b-4ab3-bd28-e0fd4930058b"
2903
2942
  ],
2904
2943
  "failures": [],
2905
2944
  "pending": [],
@@ -2910,7 +2949,7 @@
2910
2949
  "_timeout": 2000
2911
2950
  },
2912
2951
  {
2913
- "uuid": "92d3bf8a-1a32-429c-bdc6-ac9305237056",
2952
+ "uuid": "5c77380b-7e73-47a1-96ab-3713a61a6cfd",
2914
2953
  "title": "skipForward()",
2915
2954
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2916
2955
  "file": "/test/device.ts",
@@ -2930,15 +2969,15 @@
2930
2969
  "context": null,
2931
2970
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2932
2971
  "err": {},
2933
- "uuid": "d0064ed5-9570-4b08-8b76-6fc1d3296887",
2934
- "parentUUID": "92d3bf8a-1a32-429c-bdc6-ac9305237056",
2972
+ "uuid": "8e9149c6-443b-4104-bc63-1d9fd555f21f",
2973
+ "parentUUID": "5c77380b-7e73-47a1-96ab-3713a61a6cfd",
2935
2974
  "isHook": false,
2936
2975
  "skipped": false
2937
2976
  }
2938
2977
  ],
2939
2978
  "suites": [],
2940
2979
  "passes": [
2941
- "d0064ed5-9570-4b08-8b76-6fc1d3296887"
2980
+ "8e9149c6-443b-4104-bc63-1d9fd555f21f"
2942
2981
  ],
2943
2982
  "failures": [],
2944
2983
  "pending": [],
@@ -2949,7 +2988,7 @@
2949
2988
  "_timeout": 2000
2950
2989
  },
2951
2990
  {
2952
- "uuid": "6d7f5356-4fbf-4aa4-ba95-0ba2dda72075",
2991
+ "uuid": "bb41387f-294b-40f7-87e2-c8fccb808d96",
2953
2992
  "title": "stop()",
2954
2993
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2955
2994
  "file": "/test/device.ts",
@@ -2960,7 +2999,7 @@
2960
2999
  "title": "should work",
2961
3000
  "fullTitle": "NodePyATVDevice stop() should work",
2962
3001
  "timedOut": false,
2963
- "duration": 1,
3002
+ "duration": 2,
2964
3003
  "state": "passed",
2965
3004
  "speed": "fast",
2966
3005
  "pass": true,
@@ -2969,26 +3008,26 @@
2969
3008
  "context": null,
2970
3009
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
2971
3010
  "err": {},
2972
- "uuid": "710c3342-80cb-462e-b95e-e7d75159507c",
2973
- "parentUUID": "6d7f5356-4fbf-4aa4-ba95-0ba2dda72075",
3011
+ "uuid": "c0284fbe-2381-41eb-8332-cf2c8d3f5ba5",
3012
+ "parentUUID": "bb41387f-294b-40f7-87e2-c8fccb808d96",
2974
3013
  "isHook": false,
2975
3014
  "skipped": false
2976
3015
  }
2977
3016
  ],
2978
3017
  "suites": [],
2979
3018
  "passes": [
2980
- "710c3342-80cb-462e-b95e-e7d75159507c"
3019
+ "c0284fbe-2381-41eb-8332-cf2c8d3f5ba5"
2981
3020
  ],
2982
3021
  "failures": [],
2983
3022
  "pending": [],
2984
3023
  "skipped": [],
2985
- "duration": 1,
3024
+ "duration": 2,
2986
3025
  "root": false,
2987
3026
  "rootEmpty": false,
2988
3027
  "_timeout": 2000
2989
3028
  },
2990
3029
  {
2991
- "uuid": "d0f2c78a-e75a-4721-98a2-95b6ead276a4",
3030
+ "uuid": "fa349cbc-e0b5-4c06-9a99-a6c506b55e65",
2992
3031
  "title": "suspend()",
2993
3032
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
2994
3033
  "file": "/test/device.ts",
@@ -2999,7 +3038,7 @@
2999
3038
  "title": "should work",
3000
3039
  "fullTitle": "NodePyATVDevice suspend() should work",
3001
3040
  "timedOut": false,
3002
- "duration": 2,
3041
+ "duration": 1,
3003
3042
  "state": "passed",
3004
3043
  "speed": "fast",
3005
3044
  "pass": true,
@@ -3008,26 +3047,26 @@
3008
3047
  "context": null,
3009
3048
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
3010
3049
  "err": {},
3011
- "uuid": "ac460c24-8a0f-4353-9fe5-de68c15a8e84",
3012
- "parentUUID": "d0f2c78a-e75a-4721-98a2-95b6ead276a4",
3050
+ "uuid": "37bffdc3-78a8-4cab-ae20-ea310b9ed0c0",
3051
+ "parentUUID": "fa349cbc-e0b5-4c06-9a99-a6c506b55e65",
3013
3052
  "isHook": false,
3014
3053
  "skipped": false
3015
3054
  }
3016
3055
  ],
3017
3056
  "suites": [],
3018
3057
  "passes": [
3019
- "ac460c24-8a0f-4353-9fe5-de68c15a8e84"
3058
+ "37bffdc3-78a8-4cab-ae20-ea310b9ed0c0"
3020
3059
  ],
3021
3060
  "failures": [],
3022
3061
  "pending": [],
3023
3062
  "skipped": [],
3024
- "duration": 2,
3063
+ "duration": 1,
3025
3064
  "root": false,
3026
3065
  "rootEmpty": false,
3027
3066
  "_timeout": 2000
3028
3067
  },
3029
3068
  {
3030
- "uuid": "ee3c947c-ef66-4f9d-98cc-45e37c0b6488",
3069
+ "uuid": "9f5e5466-2055-45fe-bba1-d4d5d9af02ef",
3031
3070
  "title": "topMenu()",
3032
3071
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
3033
3072
  "file": "/test/device.ts",
@@ -3038,7 +3077,7 @@
3038
3077
  "title": "should work",
3039
3078
  "fullTitle": "NodePyATVDevice topMenu() should work",
3040
3079
  "timedOut": false,
3041
- "duration": 1,
3080
+ "duration": 2,
3042
3081
  "state": "passed",
3043
3082
  "speed": "fast",
3044
3083
  "pass": true,
@@ -3047,26 +3086,26 @@
3047
3086
  "context": null,
3048
3087
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
3049
3088
  "err": {},
3050
- "uuid": "4758a484-b786-465d-8c02-7cc462fb5483",
3051
- "parentUUID": "ee3c947c-ef66-4f9d-98cc-45e37c0b6488",
3089
+ "uuid": "8c63117f-ce08-4f5d-a85e-4720af3911c3",
3090
+ "parentUUID": "9f5e5466-2055-45fe-bba1-d4d5d9af02ef",
3052
3091
  "isHook": false,
3053
3092
  "skipped": false
3054
3093
  }
3055
3094
  ],
3056
3095
  "suites": [],
3057
3096
  "passes": [
3058
- "4758a484-b786-465d-8c02-7cc462fb5483"
3097
+ "8c63117f-ce08-4f5d-a85e-4720af3911c3"
3059
3098
  ],
3060
3099
  "failures": [],
3061
3100
  "pending": [],
3062
3101
  "skipped": [],
3063
- "duration": 1,
3102
+ "duration": 2,
3064
3103
  "root": false,
3065
3104
  "rootEmpty": false,
3066
3105
  "_timeout": 2000
3067
3106
  },
3068
3107
  {
3069
- "uuid": "489cc59d-df3b-4646-9b56-ff0e70129d54",
3108
+ "uuid": "d0121024-be45-4a40-bef0-f49fcbfc3b1a",
3070
3109
  "title": "up()",
3071
3110
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
3072
3111
  "file": "/test/device.ts",
@@ -3086,15 +3125,15 @@
3086
3125
  "context": null,
3087
3126
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
3088
3127
  "err": {},
3089
- "uuid": "7ccac00d-79e8-4f64-b131-c401929fbc8a",
3090
- "parentUUID": "489cc59d-df3b-4646-9b56-ff0e70129d54",
3128
+ "uuid": "dd1859c2-603f-4284-933b-5436a91c839e",
3129
+ "parentUUID": "d0121024-be45-4a40-bef0-f49fcbfc3b1a",
3091
3130
  "isHook": false,
3092
3131
  "skipped": false
3093
3132
  }
3094
3133
  ],
3095
3134
  "suites": [],
3096
3135
  "passes": [
3097
- "7ccac00d-79e8-4f64-b131-c401929fbc8a"
3136
+ "dd1859c2-603f-4284-933b-5436a91c839e"
3098
3137
  ],
3099
3138
  "failures": [],
3100
3139
  "pending": [],
@@ -3105,7 +3144,7 @@
3105
3144
  "_timeout": 2000
3106
3145
  },
3107
3146
  {
3108
- "uuid": "a0fb1cb5-903e-4764-b085-2932033254bc",
3147
+ "uuid": "3a039f35-85d1-4e90-a152-0bb912bc2e23",
3109
3148
  "title": "volumeDown()",
3110
3149
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
3111
3150
  "file": "/test/device.ts",
@@ -3125,15 +3164,15 @@
3125
3164
  "context": null,
3126
3165
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
3127
3166
  "err": {},
3128
- "uuid": "6bc6bbec-2d73-487b-9411-902b95fed32b",
3129
- "parentUUID": "a0fb1cb5-903e-4764-b085-2932033254bc",
3167
+ "uuid": "c535177e-7ed8-45a6-aa8e-31fc4b515d36",
3168
+ "parentUUID": "3a039f35-85d1-4e90-a152-0bb912bc2e23",
3130
3169
  "isHook": false,
3131
3170
  "skipped": false
3132
3171
  }
3133
3172
  ],
3134
3173
  "suites": [],
3135
3174
  "passes": [
3136
- "6bc6bbec-2d73-487b-9411-902b95fed32b"
3175
+ "c535177e-7ed8-45a6-aa8e-31fc4b515d36"
3137
3176
  ],
3138
3177
  "failures": [],
3139
3178
  "pending": [],
@@ -3144,7 +3183,7 @@
3144
3183
  "_timeout": 2000
3145
3184
  },
3146
3185
  {
3147
- "uuid": "97d444cd-574d-4ad1-8390-62517190c02d",
3186
+ "uuid": "062733f0-61b8-48b9-aa5d-5320c9bbbfc0",
3148
3187
  "title": "volumeUp()",
3149
3188
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
3150
3189
  "file": "/test/device.ts",
@@ -3164,15 +3203,15 @@
3164
3203
  "context": null,
3165
3204
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
3166
3205
  "err": {},
3167
- "uuid": "f78d9961-0b03-45a1-875f-6ab1c0867918",
3168
- "parentUUID": "97d444cd-574d-4ad1-8390-62517190c02d",
3206
+ "uuid": "ca6e7873-0889-4b2c-8cd4-823bbeb600e6",
3207
+ "parentUUID": "062733f0-61b8-48b9-aa5d-5320c9bbbfc0",
3169
3208
  "isHook": false,
3170
3209
  "skipped": false
3171
3210
  }
3172
3211
  ],
3173
3212
  "suites": [],
3174
3213
  "passes": [
3175
- "f78d9961-0b03-45a1-875f-6ab1c0867918"
3214
+ "ca6e7873-0889-4b2c-8cd4-823bbeb600e6"
3176
3215
  ],
3177
3216
  "failures": [],
3178
3217
  "pending": [],
@@ -3183,7 +3222,7 @@
3183
3222
  "_timeout": 2000
3184
3223
  },
3185
3224
  {
3186
- "uuid": "99e37a47-0321-43d3-ac2c-e72d00668717",
3225
+ "uuid": "0cc9223a-4fe1-4ae2-9cfb-6d42ad67ffa2",
3187
3226
  "title": "wakeup()",
3188
3227
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
3189
3228
  "file": "/test/device.ts",
@@ -3203,15 +3242,15 @@
3203
3242
  "context": null,
3204
3243
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
3205
3244
  "err": {},
3206
- "uuid": "9c9d1e09-e585-4bff-aab1-bac304fee555",
3207
- "parentUUID": "99e37a47-0321-43d3-ac2c-e72d00668717",
3245
+ "uuid": "8d1123f0-1dad-4045-9216-5ffe28756725",
3246
+ "parentUUID": "0cc9223a-4fe1-4ae2-9cfb-6d42ad67ffa2",
3208
3247
  "isHook": false,
3209
3248
  "skipped": false
3210
3249
  }
3211
3250
  ],
3212
3251
  "suites": [],
3213
3252
  "passes": [
3214
- "9c9d1e09-e585-4bff-aab1-bac304fee555"
3253
+ "8d1123f0-1dad-4045-9216-5ffe28756725"
3215
3254
  ],
3216
3255
  "failures": [],
3217
3256
  "pending": [],
@@ -3222,7 +3261,7 @@
3222
3261
  "_timeout": 2000
3223
3262
  },
3224
3263
  {
3225
- "uuid": "51e3a9be-3b22-49b3-baa3-2a6c28125730",
3264
+ "uuid": "2f0af716-533a-4209-baf0-c2990c5953e1",
3226
3265
  "title": "turnOff()",
3227
3266
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
3228
3267
  "file": "/test/device.ts",
@@ -3242,15 +3281,15 @@
3242
3281
  "context": null,
3243
3282
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
3244
3283
  "err": {},
3245
- "uuid": "ad85a172-93b0-42d7-8b43-64dcb3a4b85f",
3246
- "parentUUID": "51e3a9be-3b22-49b3-baa3-2a6c28125730",
3284
+ "uuid": "2ed54c40-8369-46d6-be67-b1d80b275f86",
3285
+ "parentUUID": "2f0af716-533a-4209-baf0-c2990c5953e1",
3247
3286
  "isHook": false,
3248
3287
  "skipped": false
3249
3288
  }
3250
3289
  ],
3251
3290
  "suites": [],
3252
3291
  "passes": [
3253
- "ad85a172-93b0-42d7-8b43-64dcb3a4b85f"
3292
+ "2ed54c40-8369-46d6-be67-b1d80b275f86"
3254
3293
  ],
3255
3294
  "failures": [],
3256
3295
  "pending": [],
@@ -3261,7 +3300,7 @@
3261
3300
  "_timeout": 2000
3262
3301
  },
3263
3302
  {
3264
- "uuid": "01ee2177-929d-474a-9098-dca569073914",
3303
+ "uuid": "27e18c56-b054-4ea0-a5ee-c67be5e3f34a",
3265
3304
  "title": "turnOn()",
3266
3305
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
3267
3306
  "file": "/test/device.ts",
@@ -3281,15 +3320,54 @@
3281
3320
  "context": null,
3282
3321
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('{\"result\":\"success\"}');\n })\n });\n // @ts-ignore\n yield device[key]();\n});",
3283
3322
  "err": {},
3284
- "uuid": "caadc22a-0560-4dcd-882f-aa9243c0044e",
3285
- "parentUUID": "01ee2177-929d-474a-9098-dca569073914",
3323
+ "uuid": "6aa519fc-36f7-4b59-92b3-38995f000f78",
3324
+ "parentUUID": "27e18c56-b054-4ea0-a5ee-c67be5e3f34a",
3325
+ "isHook": false,
3326
+ "skipped": false
3327
+ }
3328
+ ],
3329
+ "suites": [],
3330
+ "passes": [
3331
+ "6aa519fc-36f7-4b59-92b3-38995f000f78"
3332
+ ],
3333
+ "failures": [],
3334
+ "pending": [],
3335
+ "skipped": [],
3336
+ "duration": 1,
3337
+ "root": false,
3338
+ "rootEmpty": false,
3339
+ "_timeout": 2000
3340
+ },
3341
+ {
3342
+ "uuid": "afa18b41-8e41-45e8-bede-2c9cbc24bb14",
3343
+ "title": "launchApp()",
3344
+ "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/device.ts",
3345
+ "file": "/test/device.ts",
3346
+ "beforeHooks": [],
3347
+ "afterHooks": [],
3348
+ "tests": [
3349
+ {
3350
+ "title": "should work",
3351
+ "fullTitle": "NodePyATVDevice launchApp() should work",
3352
+ "timedOut": false,
3353
+ "duration": 1,
3354
+ "state": "passed",
3355
+ "speed": "fast",
3356
+ "pass": true,
3357
+ "fail": false,
3358
+ "pending": false,
3359
+ "context": null,
3360
+ "code": "return __awaiter(this, void 0, void 0, function* () {\n const device = new NodePyATVDevice({\n name: 'My Testdevice',\n host: '192.168.178.2',\n spawn: createFakeSpawn(cp => {\n cp.end('');\n })\n });\n yield device.launchApp('com.apple.TVShows');\n});",
3361
+ "err": {},
3362
+ "uuid": "cd660322-a73c-42a1-8e0e-21f97c71a19e",
3363
+ "parentUUID": "afa18b41-8e41-45e8-bede-2c9cbc24bb14",
3286
3364
  "isHook": false,
3287
3365
  "skipped": false
3288
3366
  }
3289
3367
  ],
3290
3368
  "suites": [],
3291
3369
  "passes": [
3292
- "caadc22a-0560-4dcd-882f-aa9243c0044e"
3370
+ "cd660322-a73c-42a1-8e0e-21f97c71a19e"
3293
3371
  ],
3294
3372
  "failures": [],
3295
3373
  "pending": [],
@@ -3310,7 +3388,7 @@
3310
3388
  "_timeout": 2000
3311
3389
  },
3312
3390
  {
3313
- "uuid": "23d6280c-ec29-4b18-b094-2a77fe02ce47",
3391
+ "uuid": "88aced76-6f77-4e9d-91e2-3ebf7977dc39",
3314
3392
  "title": "NodePyATVInstance",
3315
3393
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3316
3394
  "file": "/test/instance.ts",
@@ -3319,7 +3397,7 @@
3319
3397
  "tests": [],
3320
3398
  "suites": [
3321
3399
  {
3322
- "uuid": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3400
+ "uuid": "de2421b8-e472-420e-b761-310ce4d178d3",
3323
3401
  "title": "static version()",
3324
3402
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3325
3403
  "file": "/test/instance.ts",
@@ -3330,7 +3408,7 @@
3330
3408
  "title": "should work with pyatv [L]",
3331
3409
  "fullTitle": "NodePyATVInstance static version() should work with pyatv [L]",
3332
3410
  "timedOut": false,
3333
- "duration": 542,
3411
+ "duration": 735,
3334
3412
  "state": "passed",
3335
3413
  "speed": "slow",
3336
3414
  "pass": true,
@@ -3339,8 +3417,8 @@
3339
3417
  "context": null,
3340
3418
  "code": "return __awaiter(this, void 0, void 0, function* () {\n this.timeout(4000);\n const result = yield NodePyATVInstance.version();\n if (result.pyatv === null) {\n throw new Error('No version found for pyatv. Is it installed in test environment?');\n }\n assert.equal(typeof result.pyatv, 'string', 'result.pyatv is a string');\n assert.ok(result.pyatv.length >= 5, 'result.pyatv has content');\n assert.strictEqual(result.module, version);\n});",
3341
3419
  "err": {},
3342
- "uuid": "1fad93ad-7cff-4f00-bf32-3d023e21d0fe",
3343
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3420
+ "uuid": "ec2c1054-3371-415d-b5ff-fc84ff54da8e",
3421
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3344
3422
  "isHook": false,
3345
3423
  "skipped": false
3346
3424
  },
@@ -3357,8 +3435,8 @@
3357
3435
  "context": null,
3358
3436
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const result = yield NodePyATVInstance.version({\n spawn: createFakeSpawn(cp => {\n cp.code(1);\n cp.end('atvremote 0.7.4');\n })\n });\n assert.ok(result.pyatv);\n assert.strictEqual(result.pyatv, '0.7.4');\n});",
3359
3437
  "err": {},
3360
- "uuid": "78994be0-5dba-4568-ac57-d04886e203ec",
3361
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3438
+ "uuid": "25b2deea-5fbd-4f8f-9c76-141a731dbede",
3439
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3362
3440
  "isHook": false,
3363
3441
  "skipped": false
3364
3442
  },
@@ -3366,7 +3444,7 @@
3366
3444
  "title": "should return the module version",
3367
3445
  "fullTitle": "NodePyATVInstance static version() should return the module version",
3368
3446
  "timedOut": false,
3369
- "duration": 2,
3447
+ "duration": 1,
3370
3448
  "state": "passed",
3371
3449
  "speed": "fast",
3372
3450
  "pass": true,
@@ -3375,8 +3453,8 @@
3375
3453
  "context": null,
3376
3454
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const result = yield NodePyATVInstance.version({\n noColors: true,\n spawn: createFakeSpawn(cp => cp.code(1).end())\n });\n assert.strictEqual(result.module, version);\n});",
3377
3455
  "err": {},
3378
- "uuid": "fe208a67-9408-4472-8286-a71c49588c67",
3379
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3456
+ "uuid": "80c9e7fc-2c72-4fd6-88b8-a7e5725de6c2",
3457
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3380
3458
  "isHook": false,
3381
3459
  "skipped": false
3382
3460
  },
@@ -3393,8 +3471,8 @@
3393
3471
  "context": null,
3394
3472
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.version({\n atvremotePath: '/foo/bar',\n spawn: createFakeSpawn(cp => {\n assert.strictEqual(cp.cmd(), '/foo/bar');\n cp.code(1).end();\n })\n });\n});",
3395
3473
  "err": {},
3396
- "uuid": "afcb3337-f368-40e1-8fc4-ad30e2706715",
3397
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3474
+ "uuid": "a1985053-b1d2-4aee-8dca-22ab0ad04e9e",
3475
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3398
3476
  "isHook": false,
3399
3477
  "skipped": false
3400
3478
  },
@@ -3402,7 +3480,7 @@
3402
3480
  "title": "should work with option.debug = true",
3403
3481
  "fullTitle": "NodePyATVInstance static version() should work with option.debug = true",
3404
3482
  "timedOut": false,
3405
- "duration": 3,
3483
+ "duration": 2,
3406
3484
  "state": "passed",
3407
3485
  "speed": "fast",
3408
3486
  "pass": true,
@@ -3411,8 +3489,8 @@
3411
3489
  "context": null,
3412
3490
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.version({\n debug: true,\n spawn: createFakeSpawn(cp => cp.code(1).end())\n });\n});",
3413
3491
  "err": {},
3414
- "uuid": "934ed758-a865-4cca-90ee-25e4c23e2997",
3415
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3492
+ "uuid": "19466bad-58ca-4d06-a31d-b4b004edaf4b",
3493
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3416
3494
  "isHook": false,
3417
3495
  "skipped": false
3418
3496
  },
@@ -3429,8 +3507,8 @@
3429
3507
  "context": null,
3430
3508
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.version({\n debug: () => {\n // no debug log\n },\n noColors: true,\n spawn: createFakeSpawn(cp => cp.code(1).end())\n });\n});",
3431
3509
  "err": {},
3432
- "uuid": "a12b3582-17b5-498a-9348-5a6b61ac0db8",
3433
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3510
+ "uuid": "0b51ce09-52a2-4b70-8fcb-e496089ca56d",
3511
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3434
3512
  "isHook": false,
3435
3513
  "skipped": false
3436
3514
  },
@@ -3438,7 +3516,7 @@
3438
3516
  "title": "should return null on pyatv stderr output",
3439
3517
  "fullTitle": "NodePyATVInstance static version() should return null on pyatv stderr output",
3440
3518
  "timedOut": false,
3441
- "duration": 3,
3519
+ "duration": 2,
3442
3520
  "state": "passed",
3443
3521
  "speed": "fast",
3444
3522
  "pass": true,
@@ -3447,8 +3525,8 @@
3447
3525
  "context": null,
3448
3526
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const result = yield NodePyATVInstance.version({\n spawn: createFakeSpawn(cp => cp.stderr('Hello World!').code(123).end())\n });\n assert.strictEqual(result.pyatv, null);\n});",
3449
3527
  "err": {},
3450
- "uuid": "5e19c89b-d7a5-4859-b9a5-67e0aeb16846",
3451
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3528
+ "uuid": "6ef2851e-7f8b-416e-907f-02d839f89297",
3529
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3452
3530
  "isHook": false,
3453
3531
  "skipped": false
3454
3532
  },
@@ -3465,8 +3543,8 @@
3465
3543
  "context": null,
3466
3544
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const result = yield NodePyATVInstance.version({\n spawn: createFakeSpawn(cp => {\n cp.error(new Error('Hello world!')).end();\n })\n });\n assert.strictEqual(result.pyatv, null);\n});",
3467
3545
  "err": {},
3468
- "uuid": "25f45f5c-443d-4380-af44-85879a585f23",
3469
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3546
+ "uuid": "6fe5eac7-1e81-4633-a063-40f7037bd8e8",
3547
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3470
3548
  "isHook": false,
3471
3549
  "skipped": false
3472
3550
  },
@@ -3474,7 +3552,7 @@
3474
3552
  "title": "should return null on invalid pyatv version",
3475
3553
  "fullTitle": "NodePyATVInstance static version() should return null on invalid pyatv version",
3476
3554
  "timedOut": false,
3477
- "duration": 2,
3555
+ "duration": 0,
3478
3556
  "state": "passed",
3479
3557
  "speed": "fast",
3480
3558
  "pass": true,
@@ -3483,34 +3561,34 @@
3483
3561
  "context": null,
3484
3562
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const result = yield NodePyATVInstance.version({\n spawn: createFakeSpawn(cp => {\n cp.stdout('atvremote 42').code(1).end();\n })\n });\n assert.strictEqual(result.pyatv, null);\n});",
3485
3563
  "err": {},
3486
- "uuid": "7c03788e-125a-4398-bf38-0813c526400b",
3487
- "parentUUID": "5929ff33-f4e5-4cdb-92a1-f4285648d979",
3564
+ "uuid": "8d0685ef-c858-49a7-bc46-9111200068e7",
3565
+ "parentUUID": "de2421b8-e472-420e-b761-310ce4d178d3",
3488
3566
  "isHook": false,
3489
3567
  "skipped": false
3490
3568
  }
3491
3569
  ],
3492
3570
  "suites": [],
3493
3571
  "passes": [
3494
- "1fad93ad-7cff-4f00-bf32-3d023e21d0fe",
3495
- "78994be0-5dba-4568-ac57-d04886e203ec",
3496
- "fe208a67-9408-4472-8286-a71c49588c67",
3497
- "afcb3337-f368-40e1-8fc4-ad30e2706715",
3498
- "934ed758-a865-4cca-90ee-25e4c23e2997",
3499
- "a12b3582-17b5-498a-9348-5a6b61ac0db8",
3500
- "5e19c89b-d7a5-4859-b9a5-67e0aeb16846",
3501
- "25f45f5c-443d-4380-af44-85879a585f23",
3502
- "7c03788e-125a-4398-bf38-0813c526400b"
3572
+ "ec2c1054-3371-415d-b5ff-fc84ff54da8e",
3573
+ "25b2deea-5fbd-4f8f-9c76-141a731dbede",
3574
+ "80c9e7fc-2c72-4fd6-88b8-a7e5725de6c2",
3575
+ "a1985053-b1d2-4aee-8dca-22ab0ad04e9e",
3576
+ "19466bad-58ca-4d06-a31d-b4b004edaf4b",
3577
+ "0b51ce09-52a2-4b70-8fcb-e496089ca56d",
3578
+ "6ef2851e-7f8b-416e-907f-02d839f89297",
3579
+ "6fe5eac7-1e81-4633-a063-40f7037bd8e8",
3580
+ "8d0685ef-c858-49a7-bc46-9111200068e7"
3503
3581
  ],
3504
3582
  "failures": [],
3505
3583
  "pending": [],
3506
3584
  "skipped": [],
3507
- "duration": 560,
3585
+ "duration": 748,
3508
3586
  "root": false,
3509
3587
  "rootEmpty": false,
3510
3588
  "_timeout": 2000
3511
3589
  },
3512
3590
  {
3513
- "uuid": "c098409c-dbff-4b08-b9b5-4b516980c87c",
3591
+ "uuid": "093f8d58-9c11-42f5-b819-639a3b5f7826",
3514
3592
  "title": "static check()",
3515
3593
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3516
3594
  "file": "/test/instance.ts",
@@ -3521,7 +3599,7 @@
3521
3599
  "title": "should resolve in test environment [L]",
3522
3600
  "fullTitle": "NodePyATVInstance static check() should resolve in test environment [L]",
3523
3601
  "timedOut": false,
3524
- "duration": 5841,
3602
+ "duration": 5860,
3525
3603
  "state": "passed",
3526
3604
  "speed": "slow",
3527
3605
  "pass": true,
@@ -3530,8 +3608,8 @@
3530
3608
  "context": null,
3531
3609
  "code": "return __awaiter(this, void 0, void 0, function* () {\n this.timeout(12000);\n yield NodePyATVInstance.check();\n});",
3532
3610
  "err": {},
3533
- "uuid": "92e66d1c-d5ea-465f-8e57-f913615e2697",
3534
- "parentUUID": "c098409c-dbff-4b08-b9b5-4b516980c87c",
3611
+ "uuid": "f76cb40d-b5d0-4ab1-9626-fff9b736dd0d",
3612
+ "parentUUID": "093f8d58-9c11-42f5-b819-639a3b5f7826",
3535
3613
  "isHook": false,
3536
3614
  "skipped": false
3537
3615
  },
@@ -3548,8 +3626,8 @@
3548
3626
  "context": null,
3549
3627
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.check({\n spawn: createFakeSpawn(cp => {\n cp.error(new Error('spawn atvremote ENOENT')).code(1).end();\n })\n });\n }), /Unable to find pyatv. Is it installed?/);\n});",
3550
3628
  "err": {},
3551
- "uuid": "113b1be2-52af-4e29-b56b-5e8ace55c9c9",
3552
- "parentUUID": "c098409c-dbff-4b08-b9b5-4b516980c87c",
3629
+ "uuid": "7e6adc7e-1690-460a-b619-9b9106b638ff",
3630
+ "parentUUID": "093f8d58-9c11-42f5-b819-639a3b5f7826",
3553
3631
  "isHook": false,
3554
3632
  "skipped": false
3555
3633
  },
@@ -3557,7 +3635,7 @@
3557
3635
  "title": "should return nice error message if myatv is too old",
3558
3636
  "fullTitle": "NodePyATVInstance static check() should return nice error message if myatv is too old",
3559
3637
  "timedOut": false,
3560
- "duration": 1,
3638
+ "duration": 2,
3561
3639
  "state": "passed",
3562
3640
  "speed": "fast",
3563
3641
  "pass": true,
@@ -3566,8 +3644,8 @@
3566
3644
  "context": null,
3567
3645
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.check({\n spawn: createFakeSpawn(cp => {\n cp.stdout('atvremote 0.5.1').code(1).end();\n })\n });\n }), /Found pyatv, but unforunately it's too old. Please update pyatv./);\n});",
3568
3646
  "err": {},
3569
- "uuid": "57a5808b-b8cb-42fe-b891-8b5f67ba1da0",
3570
- "parentUUID": "c098409c-dbff-4b08-b9b5-4b516980c87c",
3647
+ "uuid": "34448d40-e49d-47b5-80d2-008b97e05a87",
3648
+ "parentUUID": "093f8d58-9c11-42f5-b819-639a3b5f7826",
3571
3649
  "isHook": false,
3572
3650
  "skipped": false
3573
3651
  },
@@ -3584,29 +3662,29 @@
3584
3662
  "context": null,
3585
3663
  "code": "return __awaiter(this, void 0, void 0, function* () {\n let i = 0;\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.check({\n spawn: createFakeSpawn(cp => {\n if (i === 0) {\n cp.stdout('atvremote 0.7.0').code(1).end();\n i++;\n }\n else {\n cp.error(new Error('spawn atvremote ENOENT')).code(1).end();\n }\n })\n });\n }), /Unable to scan for devices/);\n});",
3586
3664
  "err": {},
3587
- "uuid": "7f663704-7f34-499c-80ea-18f8d46c441a",
3588
- "parentUUID": "c098409c-dbff-4b08-b9b5-4b516980c87c",
3665
+ "uuid": "10e996ec-885b-4318-bd10-322b94302020",
3666
+ "parentUUID": "093f8d58-9c11-42f5-b819-639a3b5f7826",
3589
3667
  "isHook": false,
3590
3668
  "skipped": false
3591
3669
  }
3592
3670
  ],
3593
3671
  "suites": [],
3594
3672
  "passes": [
3595
- "92e66d1c-d5ea-465f-8e57-f913615e2697",
3596
- "113b1be2-52af-4e29-b56b-5e8ace55c9c9",
3597
- "57a5808b-b8cb-42fe-b891-8b5f67ba1da0",
3598
- "7f663704-7f34-499c-80ea-18f8d46c441a"
3673
+ "f76cb40d-b5d0-4ab1-9626-fff9b736dd0d",
3674
+ "7e6adc7e-1690-460a-b619-9b9106b638ff",
3675
+ "34448d40-e49d-47b5-80d2-008b97e05a87",
3676
+ "10e996ec-885b-4318-bd10-322b94302020"
3599
3677
  ],
3600
3678
  "failures": [],
3601
3679
  "pending": [],
3602
3680
  "skipped": [],
3603
- "duration": 5847,
3681
+ "duration": 5867,
3604
3682
  "root": false,
3605
3683
  "rootEmpty": false,
3606
3684
  "_timeout": 2000
3607
3685
  },
3608
3686
  {
3609
- "uuid": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3687
+ "uuid": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3610
3688
  "title": "static find()",
3611
3689
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3612
3690
  "file": "/test/instance.ts",
@@ -3617,7 +3695,7 @@
3617
3695
  "title": "should work [L]",
3618
3696
  "fullTitle": "NodePyATVInstance static find() should work [L]",
3619
3697
  "timedOut": false,
3620
- "duration": 5434,
3698
+ "duration": 5431,
3621
3699
  "state": "passed",
3622
3700
  "speed": "slow",
3623
3701
  "pass": true,
@@ -3626,8 +3704,8 @@
3626
3704
  "context": null,
3627
3705
  "code": "return __awaiter(this, void 0, void 0, function* () {\n this.timeout(8000);\n const result = yield NodePyATVInstance.find();\n assert.ok(Array.isArray(result));\n});",
3628
3706
  "err": {},
3629
- "uuid": "a66e7cb0-ef36-43ed-9124-52ca9e75b281",
3630
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3707
+ "uuid": "0b41ab12-d2fe-4899-939b-7b8cf1096599",
3708
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3631
3709
  "isHook": false,
3632
3710
  "skipped": false
3633
3711
  },
@@ -3644,8 +3722,8 @@
3644
3722
  "context": null,
3645
3723
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.find({\n atvscriptPath: '/foo/bar',\n spawn: createFakeSpawn(cp => {\n assert.strictEqual(cp.cmd(), '/foo/bar');\n cp.stdout({\n 'result': 'success',\n 'datetime': '2020-11-06T20:47:30.840022+01:00',\n 'devices': []\n }).end();\n })\n });\n});",
3646
3724
  "err": {},
3647
- "uuid": "fa062b5a-fbc7-4928-977e-852b9350e24d",
3648
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3725
+ "uuid": "c550dc21-5be9-40fe-b968-e480d9e1cf09",
3726
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3649
3727
  "isHook": false,
3650
3728
  "skipped": false
3651
3729
  },
@@ -3653,7 +3731,7 @@
3653
3731
  "title": "should throw error on stderr output",
3654
3732
  "fullTitle": "NodePyATVInstance static find() should throw error on stderr output",
3655
3733
  "timedOut": false,
3656
- "duration": 2,
3734
+ "duration": 1,
3657
3735
  "state": "passed",
3658
3736
  "speed": "fast",
3659
3737
  "pass": true,
@@ -3662,8 +3740,8 @@
3662
3740
  "context": null,
3663
3741
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.find({\n spawn: createFakeSpawn(cp => {\n cp.stderr('Hello World!').code(1).end();\n })\n });\n }), /Unable to execute request/);\n});",
3664
3742
  "err": {},
3665
- "uuid": "d026011b-51e5-4ca8-b079-f625b92da588",
3666
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3743
+ "uuid": "e09d785c-4b08-47c4-b13e-ef5b023d2a1d",
3744
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3667
3745
  "isHook": false,
3668
3746
  "skipped": false
3669
3747
  },
@@ -3671,7 +3749,7 @@
3671
3749
  "title": "should throw error on error",
3672
3750
  "fullTitle": "NodePyATVInstance static find() should throw error on error",
3673
3751
  "timedOut": false,
3674
- "duration": 2,
3752
+ "duration": 1,
3675
3753
  "state": "passed",
3676
3754
  "speed": "fast",
3677
3755
  "pass": true,
@@ -3680,8 +3758,8 @@
3680
3758
  "context": null,
3681
3759
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.find({\n spawn: createFakeSpawn(cp => {\n cp.error(new Error('Hello world!')).code(1).end();\n })\n });\n }), /Hello world!/);\n});",
3682
3760
  "err": {},
3683
- "uuid": "b7b9f167-ab30-4ebc-936f-6f4c000cb701",
3684
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3761
+ "uuid": "71debcec-6679-4943-892b-d59a51e4fa12",
3762
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3685
3763
  "isHook": false,
3686
3764
  "skipped": false
3687
3765
  },
@@ -3698,8 +3776,8 @@
3698
3776
  "context": null,
3699
3777
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.find({\n spawn: createFakeSpawn(cp => {\n cp.stdout(JSON.stringify({\n 'result': 'success',\n 'datetime': '2020-11-06T20:47:30.840022+01:00',\n 'devices': []\n }).substr(1)).end();\n })\n });\n }), /Unable to parse result/);\n});",
3700
3778
  "err": {},
3701
- "uuid": "8ee4bd33-4ffd-4c96-b28e-9a6e8af0a373",
3702
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3779
+ "uuid": "0ba18fd9-5878-45bb-86a0-e018c53109bf",
3780
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3703
3781
  "isHook": false,
3704
3782
  "skipped": false
3705
3783
  },
@@ -3716,8 +3794,8 @@
3716
3794
  "context": null,
3717
3795
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.find({\n spawn: createFakeSpawn(cp => {\n cp.stdout({\n result: 'error'\n }).code(1).end();\n })\n });\n }), /Unable to parse pyatv response: /);\n});",
3718
3796
  "err": {},
3719
- "uuid": "63ae8539-d747-4236-9a19-33b9725b5fac",
3720
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3797
+ "uuid": "9433f54b-b7cf-4c12-b1fe-c72325b87335",
3798
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3721
3799
  "isHook": false,
3722
3800
  "skipped": false
3723
3801
  },
@@ -3725,7 +3803,7 @@
3725
3803
  "title": "should throw error if atvscript result is without device array",
3726
3804
  "fullTitle": "NodePyATVInstance static find() should throw error if atvscript result is without device array",
3727
3805
  "timedOut": false,
3728
- "duration": 2,
3806
+ "duration": 1,
3729
3807
  "state": "passed",
3730
3808
  "speed": "fast",
3731
3809
  "pass": true,
@@ -3734,8 +3812,8 @@
3734
3812
  "context": null,
3735
3813
  "code": "return __awaiter(this, void 0, void 0, function* () {\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield NodePyATVInstance.find({\n spawn: createFakeSpawn(cp => {\n cp.stdout({\n result: 'success'\n }).code(1).end();\n })\n });\n }), /Unable to parse pyatv response: /);\n});",
3736
3814
  "err": {},
3737
- "uuid": "247dcfd1-69b1-4dfc-af01-1e38e0710321",
3738
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3815
+ "uuid": "ed2a3f48-ef22-42f4-b9ce-62e22e24815d",
3816
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3739
3817
  "isHook": false,
3740
3818
  "skipped": false
3741
3819
  },
@@ -3743,7 +3821,7 @@
3743
3821
  "title": "should work if devices are without device_info / services",
3744
3822
  "fullTitle": "NodePyATVInstance static find() should work if devices are without device_info / services",
3745
3823
  "timedOut": false,
3746
- "duration": 1,
3824
+ "duration": 2,
3747
3825
  "state": "passed",
3748
3826
  "speed": "fast",
3749
3827
  "pass": true,
@@ -3752,8 +3830,8 @@
3752
3830
  "context": null,
3753
3831
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const devices = yield NodePyATVInstance.find({\n spawn: createFakeSpawn(cp => {\n cp.stdout({\n result: 'success',\n datetime: '2020-11-06T20:47:30.840022+01:00',\n devices: [\n {\n name: 'Vardagsrum',\n address: '10.0.10.81',\n identifier: 'xxx'\n }\n ]\n }).code(1).end();\n })\n });\n assert.strictEqual(devices.length, 1);\n assert.strictEqual(devices[0].name, 'Vardagsrum');\n assert.strictEqual(devices[0].host, '10.0.10.81');\n assert.strictEqual(devices[0].id, 'xxx');\n assert.strictEqual(devices[0].model, undefined);\n assert.strictEqual(devices[0].modelName, undefined);\n assert.strictEqual(devices[0].os, undefined);\n assert.strictEqual(devices[0].version, undefined);\n assert.deepStrictEqual(devices[0].services, undefined);\n});",
3754
3832
  "err": {},
3755
- "uuid": "f7778b9d-63b3-4554-aeca-3bd9d794f285",
3756
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3833
+ "uuid": "81f755c8-3c8f-43cc-942c-f2aefe29bf8c",
3834
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3757
3835
  "isHook": false,
3758
3836
  "skipped": false
3759
3837
  },
@@ -3770,34 +3848,34 @@
3770
3848
  "context": null,
3771
3849
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const devices = yield NodePyATVInstance.find({\n spawn: createFakeSpawn(cp => {\n cp.stdout({\n result: 'success',\n datetime: '2020-11-06T20:47:30.840022+01:00',\n devices: [\n {\n name: 'Vardagsrum',\n address: '10.0.10.81',\n identifier: 'xxx',\n device_info: {\n 'model': 'Gen4K',\n 'model_str': 'Apple TV 4K',\n 'operating_system': 'TvOS',\n 'version': '15.5.1'\n },\n services: [\n {\n protocol: 'mrp',\n port: 49152\n },\n {\n protocol: 'airplay',\n port: 7000\n }\n ]\n }\n ]\n }).code(1).end();\n })\n });\n assert.strictEqual(devices.length, 1);\n assert.strictEqual(devices[0].name, 'Vardagsrum');\n assert.strictEqual(devices[0].host, '10.0.10.81');\n assert.strictEqual(devices[0].id, 'xxx');\n assert.strictEqual(devices[0].model, 'Gen4K');\n assert.strictEqual(devices[0].modelName, 'Apple TV 4K');\n assert.strictEqual(devices[0].os, 'TvOS');\n assert.strictEqual(devices[0].version, '15.5.1');\n assert.deepStrictEqual(devices[0].services, [\n {\n protocol: NodePyATVProtocol.mrp,\n port: 49152\n },\n {\n protocol: NodePyATVProtocol.airplay,\n port: 7000\n }\n ]);\n});",
3772
3850
  "err": {},
3773
- "uuid": "b4c7054f-08be-4207-a896-4680b1571757",
3774
- "parentUUID": "a9955bdd-2e71-4d0c-b30a-696454d222c4",
3851
+ "uuid": "ad4f7b51-c300-40b5-9290-76c2c5a18982",
3852
+ "parentUUID": "5703ef4f-da40-4bb1-acb8-788afe72336f",
3775
3853
  "isHook": false,
3776
3854
  "skipped": false
3777
3855
  }
3778
3856
  ],
3779
3857
  "suites": [],
3780
3858
  "passes": [
3781
- "a66e7cb0-ef36-43ed-9124-52ca9e75b281",
3782
- "fa062b5a-fbc7-4928-977e-852b9350e24d",
3783
- "d026011b-51e5-4ca8-b079-f625b92da588",
3784
- "b7b9f167-ab30-4ebc-936f-6f4c000cb701",
3785
- "8ee4bd33-4ffd-4c96-b28e-9a6e8af0a373",
3786
- "63ae8539-d747-4236-9a19-33b9725b5fac",
3787
- "247dcfd1-69b1-4dfc-af01-1e38e0710321",
3788
- "f7778b9d-63b3-4554-aeca-3bd9d794f285",
3789
- "b4c7054f-08be-4207-a896-4680b1571757"
3859
+ "0b41ab12-d2fe-4899-939b-7b8cf1096599",
3860
+ "c550dc21-5be9-40fe-b968-e480d9e1cf09",
3861
+ "e09d785c-4b08-47c4-b13e-ef5b023d2a1d",
3862
+ "71debcec-6679-4943-892b-d59a51e4fa12",
3863
+ "0ba18fd9-5878-45bb-86a0-e018c53109bf",
3864
+ "9433f54b-b7cf-4c12-b1fe-c72325b87335",
3865
+ "ed2a3f48-ef22-42f4-b9ce-62e22e24815d",
3866
+ "81f755c8-3c8f-43cc-942c-f2aefe29bf8c",
3867
+ "ad4f7b51-c300-40b5-9290-76c2c5a18982"
3790
3868
  ],
3791
3869
  "failures": [],
3792
3870
  "pending": [],
3793
3871
  "skipped": [],
3794
- "duration": 5447,
3872
+ "duration": 5442,
3795
3873
  "root": false,
3796
3874
  "rootEmpty": false,
3797
3875
  "_timeout": 2000
3798
3876
  },
3799
3877
  {
3800
- "uuid": "74cae41a-8d6d-4d9f-a6cf-d4f87d44bcda",
3878
+ "uuid": "8a605b09-cd84-432d-a1fe-3f37308a6989",
3801
3879
  "title": "static device()",
3802
3880
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3803
3881
  "file": "/test/instance.ts",
@@ -3817,15 +3895,15 @@
3817
3895
  "context": null,
3818
3896
  "code": "const device = NodePyATVInstance.device({ host: '192.168.178.6', name: 'My Testdevice' });\nassert.strictEqual(device.host, '192.168.178.6');\nassert.strictEqual(device.name, 'My Testdevice');",
3819
3897
  "err": {},
3820
- "uuid": "e9a5f83f-6a76-4e82-bf0b-d8267e3dbfad",
3821
- "parentUUID": "74cae41a-8d6d-4d9f-a6cf-d4f87d44bcda",
3898
+ "uuid": "06bbe85b-199c-4633-b85f-299f6e89021c",
3899
+ "parentUUID": "8a605b09-cd84-432d-a1fe-3f37308a6989",
3822
3900
  "isHook": false,
3823
3901
  "skipped": false
3824
3902
  }
3825
3903
  ],
3826
3904
  "suites": [],
3827
3905
  "passes": [
3828
- "e9a5f83f-6a76-4e82-bf0b-d8267e3dbfad"
3906
+ "06bbe85b-199c-4633-b85f-299f6e89021c"
3829
3907
  ],
3830
3908
  "failures": [],
3831
3909
  "pending": [],
@@ -3836,7 +3914,7 @@
3836
3914
  "_timeout": 2000
3837
3915
  },
3838
3916
  {
3839
- "uuid": "8c1d0c3e-f7df-4401-aa24-1b23c1b38841",
3917
+ "uuid": "411a2966-f1e7-484f-92f4-fd5cd5e48a80",
3840
3918
  "title": "version()",
3841
3919
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3842
3920
  "file": "/test/instance.ts",
@@ -3856,15 +3934,15 @@
3856
3934
  "context": null,
3857
3935
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const i = new NodePyATVInstance({ atvremotePath: 'test' });\n yield i.version({\n spawn: createFakeSpawn(cp => {\n assert.strictEqual(cp.cmd(), 'test');\n cp.code(1).end();\n })\n });\n});",
3858
3936
  "err": {},
3859
- "uuid": "8c11266e-c14e-4ea0-ac41-2cda7ed60da5",
3860
- "parentUUID": "8c1d0c3e-f7df-4401-aa24-1b23c1b38841",
3937
+ "uuid": "ac14037f-8ef6-4671-8624-c70caa4ee7b1",
3938
+ "parentUUID": "411a2966-f1e7-484f-92f4-fd5cd5e48a80",
3861
3939
  "isHook": false,
3862
3940
  "skipped": false
3863
3941
  }
3864
3942
  ],
3865
3943
  "suites": [],
3866
3944
  "passes": [
3867
- "8c11266e-c14e-4ea0-ac41-2cda7ed60da5"
3945
+ "ac14037f-8ef6-4671-8624-c70caa4ee7b1"
3868
3946
  ],
3869
3947
  "failures": [],
3870
3948
  "pending": [],
@@ -3875,7 +3953,7 @@
3875
3953
  "_timeout": 2000
3876
3954
  },
3877
3955
  {
3878
- "uuid": "0bb477ad-6f63-4edb-8c3c-233d33acfe0e",
3956
+ "uuid": "bef6d662-0d9a-466d-b56c-782c783fd7e6",
3879
3957
  "title": "check()",
3880
3958
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3881
3959
  "file": "/test/instance.ts",
@@ -3895,15 +3973,15 @@
3895
3973
  "context": null,
3896
3974
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const i = new NodePyATVInstance({ atvremotePath: 'test' });\n yield assert.rejects(() => __awaiter(this, void 0, void 0, function* () {\n yield i.check({\n spawn: createFakeSpawn(cp => {\n assert.strictEqual(cp.cmd(), 'test');\n cp.error(new Error('spawn atvremote ENOENT')).code(1).end();\n })\n });\n }), /Unable to find pyatv. Is it installed?/);\n});",
3897
3975
  "err": {},
3898
- "uuid": "b4033662-6dc9-4ec9-9b76-cb461b22accb",
3899
- "parentUUID": "0bb477ad-6f63-4edb-8c3c-233d33acfe0e",
3976
+ "uuid": "59f4d955-7fe8-4617-8def-39c372949d62",
3977
+ "parentUUID": "bef6d662-0d9a-466d-b56c-782c783fd7e6",
3900
3978
  "isHook": false,
3901
3979
  "skipped": false
3902
3980
  }
3903
3981
  ],
3904
3982
  "suites": [],
3905
3983
  "passes": [
3906
- "b4033662-6dc9-4ec9-9b76-cb461b22accb"
3984
+ "59f4d955-7fe8-4617-8def-39c372949d62"
3907
3985
  ],
3908
3986
  "failures": [],
3909
3987
  "pending": [],
@@ -3914,7 +3992,7 @@
3914
3992
  "_timeout": 2000
3915
3993
  },
3916
3994
  {
3917
- "uuid": "ab7d090f-cb1c-4aa8-a998-9f2e1ed16063",
3995
+ "uuid": "e2a6bd24-7b11-4daf-adba-c12628ba7ee7",
3918
3996
  "title": "find()",
3919
3997
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3920
3998
  "file": "/test/instance.ts",
@@ -3934,15 +4012,15 @@
3934
4012
  "context": null,
3935
4013
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const i = new NodePyATVInstance({ atvscriptPath: 'test' });\n yield i.find({\n spawn: createFakeSpawn(cp => {\n assert.strictEqual(cp.cmd(), 'test');\n cp.stdout({\n 'result': 'success',\n 'datetime': '2020-11-06T20:47:30.840022+01:00',\n 'devices': []\n }).end();\n })\n });\n});",
3936
4014
  "err": {},
3937
- "uuid": "c22d9e49-8713-414c-a90f-589687db94ed",
3938
- "parentUUID": "ab7d090f-cb1c-4aa8-a998-9f2e1ed16063",
4015
+ "uuid": "4dfdd1e5-b935-49d4-bee4-43a2959dfd7e",
4016
+ "parentUUID": "e2a6bd24-7b11-4daf-adba-c12628ba7ee7",
3939
4017
  "isHook": false,
3940
4018
  "skipped": false
3941
4019
  }
3942
4020
  ],
3943
4021
  "suites": [],
3944
4022
  "passes": [
3945
- "c22d9e49-8713-414c-a90f-589687db94ed"
4023
+ "4dfdd1e5-b935-49d4-bee4-43a2959dfd7e"
3946
4024
  ],
3947
4025
  "failures": [],
3948
4026
  "pending": [],
@@ -3953,7 +4031,7 @@
3953
4031
  "_timeout": 2000
3954
4032
  },
3955
4033
  {
3956
- "uuid": "de2ab1e4-d3e5-4bc8-9cc8-d518809a4c1c",
4034
+ "uuid": "aa35a301-7580-4dac-914d-50c4470b4934",
3957
4035
  "title": "device()",
3958
4036
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3959
4037
  "file": "/test/instance.ts",
@@ -3973,15 +4051,15 @@
3973
4051
  "context": null,
3974
4052
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const i = new NodePyATVInstance({ debug: true });\n const d = i.device({ name: 'My Testdevice', host: '192.168.178.2' });\n assert.deepStrictEqual(d.debug, true);\n});",
3975
4053
  "err": {},
3976
- "uuid": "724fb414-d7b5-4f49-b986-9153c6a445e3",
3977
- "parentUUID": "de2ab1e4-d3e5-4bc8-9cc8-d518809a4c1c",
4054
+ "uuid": "d3242d71-4abe-45bf-89a1-c6f245c00835",
4055
+ "parentUUID": "aa35a301-7580-4dac-914d-50c4470b4934",
3978
4056
  "isHook": false,
3979
4057
  "skipped": false
3980
4058
  }
3981
4059
  ],
3982
4060
  "suites": [],
3983
4061
  "passes": [
3984
- "724fb414-d7b5-4f49-b986-9153c6a445e3"
4062
+ "d3242d71-4abe-45bf-89a1-c6f245c00835"
3985
4063
  ],
3986
4064
  "failures": [],
3987
4065
  "pending": [],
@@ -3992,7 +4070,7 @@
3992
4070
  "_timeout": 2000
3993
4071
  },
3994
4072
  {
3995
- "uuid": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4073
+ "uuid": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
3996
4074
  "title": "Type Exports",
3997
4075
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/instance.ts",
3998
4076
  "file": "/test/instance.ts",
@@ -4012,8 +4090,8 @@
4012
4090
  "context": null,
4013
4091
  "code": "assert.ok(NodePyATVProtocol);",
4014
4092
  "err": {},
4015
- "uuid": "a36e24bf-e385-4ff0-b713-19c66c5621f0",
4016
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4093
+ "uuid": "46d53f97-19eb-4c84-a74a-1ecadd3a7abd",
4094
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4017
4095
  "isHook": false,
4018
4096
  "skipped": false
4019
4097
  },
@@ -4030,8 +4108,8 @@
4030
4108
  "context": null,
4031
4109
  "code": "assert.ok(NodePyATVMediaType);",
4032
4110
  "err": {},
4033
- "uuid": "97853249-6540-419f-80f2-5950bd50a022",
4034
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4111
+ "uuid": "faaf7c1c-ed42-4183-9fd3-912bd4bd874a",
4112
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4035
4113
  "isHook": false,
4036
4114
  "skipped": false
4037
4115
  },
@@ -4048,8 +4126,8 @@
4048
4126
  "context": null,
4049
4127
  "code": "assert.ok(NodePyATVDeviceEvent);",
4050
4128
  "err": {},
4051
- "uuid": "ff1b3bd9-f9b0-438a-9b46-111545f47fe1",
4052
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4129
+ "uuid": "cad8fca0-f53c-448f-863f-b686e344b53d",
4130
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4053
4131
  "isHook": false,
4054
4132
  "skipped": false
4055
4133
  },
@@ -4066,8 +4144,8 @@
4066
4144
  "context": null,
4067
4145
  "code": "assert.ok(NodePyATVDeviceState);",
4068
4146
  "err": {},
4069
- "uuid": "f186c1f5-fa78-4d09-87df-1b534cf1477d",
4070
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4147
+ "uuid": "f3dfd671-38e0-473a-b509-d110be4dcabd",
4148
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4071
4149
  "isHook": false,
4072
4150
  "skipped": false
4073
4151
  },
@@ -4084,8 +4162,8 @@
4084
4162
  "context": null,
4085
4163
  "code": "assert.ok(NodePyATVRepeatState);",
4086
4164
  "err": {},
4087
- "uuid": "21943214-262e-41dc-910d-b739b75ab1a4",
4088
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4165
+ "uuid": "65b56aaf-6511-4a3f-90ea-b27030635025",
4166
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4089
4167
  "isHook": false,
4090
4168
  "skipped": false
4091
4169
  },
@@ -4102,8 +4180,8 @@
4102
4180
  "context": null,
4103
4181
  "code": "assert.ok(NodePyATVShuffleState);",
4104
4182
  "err": {},
4105
- "uuid": "0d77d896-6e31-4d21-afab-e2ccfc7a59a7",
4106
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4183
+ "uuid": "831fc229-68d0-4df9-bd4d-a33eb086b7cb",
4184
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4107
4185
  "isHook": false,
4108
4186
  "skipped": false
4109
4187
  },
@@ -4120,8 +4198,8 @@
4120
4198
  "context": null,
4121
4199
  "code": "assert.ok(NodePyATVKeys);",
4122
4200
  "err": {},
4123
- "uuid": "e269b5d3-d9a0-4f39-a350-aea224d0002b",
4124
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4201
+ "uuid": "0d62f42d-c934-4154-969e-5305454b2533",
4202
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4125
4203
  "isHook": false,
4126
4204
  "skipped": false
4127
4205
  },
@@ -4138,8 +4216,8 @@
4138
4216
  "context": null,
4139
4217
  "code": "assert.ok(NodePyATVListenerState);",
4140
4218
  "err": {},
4141
- "uuid": "1657afcf-f04f-4037-82a1-b386c9d68b52",
4142
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4219
+ "uuid": "18f2d450-0005-4dae-b5a4-e8fef42def36",
4220
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4143
4221
  "isHook": false,
4144
4222
  "skipped": false
4145
4223
  },
@@ -4156,23 +4234,23 @@
4156
4234
  "context": null,
4157
4235
  "code": "assert.ok(NodePyATVPowerState);",
4158
4236
  "err": {},
4159
- "uuid": "20f36e22-2fbc-4b33-8dc8-9d08552a8ca0",
4160
- "parentUUID": "5c41cebe-2bdf-4b44-a726-97dc959676bb",
4237
+ "uuid": "0253a86d-f529-4620-851e-28455b67e28f",
4238
+ "parentUUID": "a52dda42-c9c9-4958-91eb-5f5bf1a4b49b",
4161
4239
  "isHook": false,
4162
4240
  "skipped": false
4163
4241
  }
4164
4242
  ],
4165
4243
  "suites": [],
4166
4244
  "passes": [
4167
- "a36e24bf-e385-4ff0-b713-19c66c5621f0",
4168
- "97853249-6540-419f-80f2-5950bd50a022",
4169
- "ff1b3bd9-f9b0-438a-9b46-111545f47fe1",
4170
- "f186c1f5-fa78-4d09-87df-1b534cf1477d",
4171
- "21943214-262e-41dc-910d-b739b75ab1a4",
4172
- "0d77d896-6e31-4d21-afab-e2ccfc7a59a7",
4173
- "e269b5d3-d9a0-4f39-a350-aea224d0002b",
4174
- "1657afcf-f04f-4037-82a1-b386c9d68b52",
4175
- "20f36e22-2fbc-4b33-8dc8-9d08552a8ca0"
4245
+ "46d53f97-19eb-4c84-a74a-1ecadd3a7abd",
4246
+ "faaf7c1c-ed42-4183-9fd3-912bd4bd874a",
4247
+ "cad8fca0-f53c-448f-863f-b686e344b53d",
4248
+ "f3dfd671-38e0-473a-b509-d110be4dcabd",
4249
+ "65b56aaf-6511-4a3f-90ea-b27030635025",
4250
+ "831fc229-68d0-4df9-bd4d-a33eb086b7cb",
4251
+ "0d62f42d-c934-4154-969e-5305454b2533",
4252
+ "18f2d450-0005-4dae-b5a4-e8fef42def36",
4253
+ "0253a86d-f529-4620-851e-28455b67e28f"
4176
4254
  ],
4177
4255
  "failures": [],
4178
4256
  "pending": [],
@@ -4193,7 +4271,7 @@
4193
4271
  "_timeout": 2000
4194
4272
  },
4195
4273
  {
4196
- "uuid": "188b6e16-247b-4a93-b14e-82357e2dccf0",
4274
+ "uuid": "358ecf86-0785-4f13-84b9-c527e6383350",
4197
4275
  "title": "Tools",
4198
4276
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/tools.ts",
4199
4277
  "file": "/test/tools.ts",
@@ -4202,7 +4280,7 @@
4202
4280
  "tests": [],
4203
4281
  "suites": [
4204
4282
  {
4205
- "uuid": "6d66f6f2-b01e-49f6-a967-1e565c9d5ab3",
4283
+ "uuid": "61190e8e-cae8-472f-b898-88df8dbeb033",
4206
4284
  "title": "addRequestId() / removeRequestId()",
4207
4285
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/tools.ts",
4208
4286
  "file": "/test/tools.ts",
@@ -4222,8 +4300,8 @@
4222
4300
  "context": null,
4223
4301
  "code": "const id = addRequestId();\nassert.strictEqual(typeof id, 'string');\nremoveRequestId(id);",
4224
4302
  "err": {},
4225
- "uuid": "87d07ac2-ac75-4088-bcd8-157840ac6bf1",
4226
- "parentUUID": "6d66f6f2-b01e-49f6-a967-1e565c9d5ab3",
4303
+ "uuid": "5258c0ef-e705-43e0-b0c7-154d1a2abfc3",
4304
+ "parentUUID": "61190e8e-cae8-472f-b898-88df8dbeb033",
4227
4305
  "isHook": false,
4228
4306
  "skipped": false
4229
4307
  },
@@ -4240,16 +4318,16 @@
4240
4318
  "context": null,
4241
4319
  "code": "removeRequestId('FOO');",
4242
4320
  "err": {},
4243
- "uuid": "131a7831-a4d2-432b-8085-a040175610a7",
4244
- "parentUUID": "6d66f6f2-b01e-49f6-a967-1e565c9d5ab3",
4321
+ "uuid": "aa8ba762-adb3-401c-8e54-a7bd291899c8",
4322
+ "parentUUID": "61190e8e-cae8-472f-b898-88df8dbeb033",
4245
4323
  "isHook": false,
4246
4324
  "skipped": false
4247
4325
  }
4248
4326
  ],
4249
4327
  "suites": [],
4250
4328
  "passes": [
4251
- "87d07ac2-ac75-4088-bcd8-157840ac6bf1",
4252
- "131a7831-a4d2-432b-8085-a040175610a7"
4329
+ "5258c0ef-e705-43e0-b0c7-154d1a2abfc3",
4330
+ "aa8ba762-adb3-401c-8e54-a7bd291899c8"
4253
4331
  ],
4254
4332
  "failures": [],
4255
4333
  "pending": [],
@@ -4260,7 +4338,7 @@
4260
4338
  "_timeout": 2000
4261
4339
  },
4262
4340
  {
4263
- "uuid": "1f4b37d5-c5d6-42ae-9bee-c2ea93d88bc2",
4341
+ "uuid": "d214f38d-34fe-44e1-9756-47424e5985a1",
4264
4342
  "title": "debug()",
4265
4343
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/tools.ts",
4266
4344
  "file": "/test/tools.ts",
@@ -4280,8 +4358,8 @@
4280
4358
  "context": null,
4281
4359
  "code": "debug('TEST', 'Hello World.', {});",
4282
4360
  "err": {},
4283
- "uuid": "bd1cb9cf-edc3-4d4a-bff8-a240b4e5a4bc",
4284
- "parentUUID": "1f4b37d5-c5d6-42ae-9bee-c2ea93d88bc2",
4361
+ "uuid": "b062c1ee-b006-4c99-9737-b13b34e62167",
4362
+ "parentUUID": "d214f38d-34fe-44e1-9756-47424e5985a1",
4285
4363
  "isHook": false,
4286
4364
  "skipped": false
4287
4365
  },
@@ -4298,8 +4376,8 @@
4298
4376
  "context": null,
4299
4377
  "code": "debug('TEST', 'Hello World.', { debug: true });",
4300
4378
  "err": {},
4301
- "uuid": "2cb8449b-4885-48f8-a38c-3c7286d9617a",
4302
- "parentUUID": "1f4b37d5-c5d6-42ae-9bee-c2ea93d88bc2",
4379
+ "uuid": "d9da87f3-e8bd-406c-8294-92fc048dd1b2",
4380
+ "parentUUID": "d214f38d-34fe-44e1-9756-47424e5985a1",
4303
4381
  "isHook": false,
4304
4382
  "skipped": false
4305
4383
  },
@@ -4316,8 +4394,8 @@
4316
4394
  "context": null,
4317
4395
  "code": "debug('TEST', 'Hello World.', {\n debug: function (msg) {\n assert.strictEqual(this, null);\n assert.ok(msg.includes('Hello World'));\n }\n});",
4318
4396
  "err": {},
4319
- "uuid": "517b40e0-cba5-49cf-ac8f-bd510d9cc34b",
4320
- "parentUUID": "1f4b37d5-c5d6-42ae-9bee-c2ea93d88bc2",
4397
+ "uuid": "42757f0d-a544-4636-bc6f-7c3b1b0d2fe2",
4398
+ "parentUUID": "d214f38d-34fe-44e1-9756-47424e5985a1",
4321
4399
  "isHook": false,
4322
4400
  "skipped": false
4323
4401
  },
@@ -4334,8 +4412,8 @@
4334
4412
  "context": null,
4335
4413
  "code": "debug('TEST', 'Hello World.', { noColors: true });",
4336
4414
  "err": {},
4337
- "uuid": "ea23070d-7f4b-4636-8506-cf645dacd293",
4338
- "parentUUID": "1f4b37d5-c5d6-42ae-9bee-c2ea93d88bc2",
4415
+ "uuid": "b47a3251-4df4-420d-a97d-45ecc38d0274",
4416
+ "parentUUID": "d214f38d-34fe-44e1-9756-47424e5985a1",
4339
4417
  "isHook": false,
4340
4418
  "skipped": false
4341
4419
  },
@@ -4352,19 +4430,19 @@
4352
4430
  "context": null,
4353
4431
  "code": "debug('TEST', 'Hello World.', {\n noColors: true,\n debug: function (msg) {\n assert.strictEqual(this, null);\n assert.strictEqual(msg, '[node-pyatv][TEST] Hello World.');\n }\n});",
4354
4432
  "err": {},
4355
- "uuid": "a2589424-71bf-4252-98ba-b56d85e272a8",
4356
- "parentUUID": "1f4b37d5-c5d6-42ae-9bee-c2ea93d88bc2",
4433
+ "uuid": "497393de-5b58-4995-8858-5671e876955b",
4434
+ "parentUUID": "d214f38d-34fe-44e1-9756-47424e5985a1",
4357
4435
  "isHook": false,
4358
4436
  "skipped": false
4359
4437
  }
4360
4438
  ],
4361
4439
  "suites": [],
4362
4440
  "passes": [
4363
- "bd1cb9cf-edc3-4d4a-bff8-a240b4e5a4bc",
4364
- "2cb8449b-4885-48f8-a38c-3c7286d9617a",
4365
- "517b40e0-cba5-49cf-ac8f-bd510d9cc34b",
4366
- "ea23070d-7f4b-4636-8506-cf645dacd293",
4367
- "a2589424-71bf-4252-98ba-b56d85e272a8"
4441
+ "b062c1ee-b006-4c99-9737-b13b34e62167",
4442
+ "d9da87f3-e8bd-406c-8294-92fc048dd1b2",
4443
+ "42757f0d-a544-4636-bc6f-7c3b1b0d2fe2",
4444
+ "b47a3251-4df4-420d-a97d-45ecc38d0274",
4445
+ "497393de-5b58-4995-8858-5671e876955b"
4368
4446
  ],
4369
4447
  "failures": [],
4370
4448
  "pending": [],
@@ -4375,7 +4453,7 @@
4375
4453
  "_timeout": 2000
4376
4454
  },
4377
4455
  {
4378
- "uuid": "a59143b5-60cf-48c5-b357-69127a49bc98",
4456
+ "uuid": "308066ac-4631-44b6-984c-bb2b5d01f5f8",
4379
4457
  "title": "getExecutable()",
4380
4458
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/tools.ts",
4381
4459
  "file": "/test/tools.ts",
@@ -4395,8 +4473,8 @@
4395
4473
  "context": null,
4396
4474
  "code": "const result = getExecutable(NodePyATVExecutableType.atvremote, {\n atvremotePath: '/tmp/1',\n atvscriptPath: '/tmp/2'\n});\nassert.strictEqual(result, '/tmp/1');",
4397
4475
  "err": {},
4398
- "uuid": "8fc0657e-844a-4424-aa38-a9d0fa1e385e",
4399
- "parentUUID": "a59143b5-60cf-48c5-b357-69127a49bc98",
4476
+ "uuid": "3725dfaa-6ee1-4f43-8f8a-faa52da0bbe3",
4477
+ "parentUUID": "308066ac-4631-44b6-984c-bb2b5d01f5f8",
4400
4478
  "isHook": false,
4401
4479
  "skipped": false
4402
4480
  },
@@ -4413,8 +4491,8 @@
4413
4491
  "context": null,
4414
4492
  "code": "const result = getExecutable(NodePyATVExecutableType.atvscript, {\n atvremotePath: '/tmp/1',\n atvscriptPath: '/tmp/2'\n});\nassert.strictEqual(result, '/tmp/2');",
4415
4493
  "err": {},
4416
- "uuid": "00152709-9972-48f5-af96-bde61445e39e",
4417
- "parentUUID": "a59143b5-60cf-48c5-b357-69127a49bc98",
4494
+ "uuid": "edf45df6-608b-4cc6-ba33-8a44f7a4b13c",
4495
+ "parentUUID": "308066ac-4631-44b6-984c-bb2b5d01f5f8",
4418
4496
  "isHook": false,
4419
4497
  "skipped": false
4420
4498
  },
@@ -4431,8 +4509,8 @@
4431
4509
  "context": null,
4432
4510
  "code": "const result = getExecutable(NodePyATVExecutableType.atvremote, {\n atvscriptPath: '/tmp'\n});\nassert.strictEqual(result, 'atvremote');",
4433
4511
  "err": {},
4434
- "uuid": "cd78f3c4-aceb-4e43-8f74-dc552edca7b8",
4435
- "parentUUID": "a59143b5-60cf-48c5-b357-69127a49bc98",
4512
+ "uuid": "f07602d0-ba3b-45ea-b561-92e2a770eb9c",
4513
+ "parentUUID": "308066ac-4631-44b6-984c-bb2b5d01f5f8",
4436
4514
  "isHook": false,
4437
4515
  "skipped": false
4438
4516
  },
@@ -4449,18 +4527,18 @@
4449
4527
  "context": null,
4450
4528
  "code": "const result = getExecutable(NodePyATVExecutableType.atvscript, {\n atvremotePath: '/tmp'\n});\nassert.strictEqual(result, 'atvscript');",
4451
4529
  "err": {},
4452
- "uuid": "b1d87594-4815-4f9f-a37d-b2d0ccb37d61",
4453
- "parentUUID": "a59143b5-60cf-48c5-b357-69127a49bc98",
4530
+ "uuid": "b522a000-ca4a-46e8-87ef-4446684f5274",
4531
+ "parentUUID": "308066ac-4631-44b6-984c-bb2b5d01f5f8",
4454
4532
  "isHook": false,
4455
4533
  "skipped": false
4456
4534
  }
4457
4535
  ],
4458
4536
  "suites": [],
4459
4537
  "passes": [
4460
- "8fc0657e-844a-4424-aa38-a9d0fa1e385e",
4461
- "00152709-9972-48f5-af96-bde61445e39e",
4462
- "cd78f3c4-aceb-4e43-8f74-dc552edca7b8",
4463
- "b1d87594-4815-4f9f-a37d-b2d0ccb37d61"
4538
+ "3725dfaa-6ee1-4f43-8f8a-faa52da0bbe3",
4539
+ "edf45df6-608b-4cc6-ba33-8a44f7a4b13c",
4540
+ "f07602d0-ba3b-45ea-b561-92e2a770eb9c",
4541
+ "b522a000-ca4a-46e8-87ef-4446684f5274"
4464
4542
  ],
4465
4543
  "failures": [],
4466
4544
  "pending": [],
@@ -4471,7 +4549,7 @@
4471
4549
  "_timeout": 2000
4472
4550
  },
4473
4551
  {
4474
- "uuid": "19ba22a7-fa3c-4736-9cd3-66f598927824",
4552
+ "uuid": "e311694b-9c19-487d-8ecc-e555af5cdf4f",
4475
4553
  "title": "getParameters()",
4476
4554
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/tools.ts",
4477
4555
  "file": "/test/tools.ts",
@@ -4491,8 +4569,8 @@
4491
4569
  "context": null,
4492
4570
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const result = yield getParamters();\n assert.deepEqual(result, []);\n});",
4493
4571
  "err": {},
4494
- "uuid": "b6d82914-51b0-4abb-b9c2-6f6f1732a841",
4495
- "parentUUID": "19ba22a7-fa3c-4736-9cd3-66f598927824",
4572
+ "uuid": "b4fde6b3-fa93-4c70-b4da-4d489c705144",
4573
+ "parentUUID": "e311694b-9c19-487d-8ecc-e555af5cdf4f",
4496
4574
  "isHook": false,
4497
4575
  "skipped": false
4498
4576
  },
@@ -4509,8 +4587,8 @@
4509
4587
  "context": null,
4510
4588
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const result = yield getParamters({\n host: '192.168.178.2'\n });\n assert.deepEqual(result, ['-s', '192.168.178.2']);\n});",
4511
4589
  "err": {},
4512
- "uuid": "b8ecc261-918f-4045-aecc-50e6dc52805a",
4513
- "parentUUID": "19ba22a7-fa3c-4736-9cd3-66f598927824",
4590
+ "uuid": "a695f5ec-f5b1-4e08-9097-2bd41a6cbed0",
4591
+ "parentUUID": "e311694b-9c19-487d-8ecc-e555af5cdf4f",
4514
4592
  "isHook": false,
4515
4593
  "skipped": false
4516
4594
  },
@@ -4518,7 +4596,7 @@
4518
4596
  "title": "full case",
4519
4597
  "fullTitle": "Tools getParameters() full case",
4520
4598
  "timedOut": false,
4521
- "duration": 1,
4599
+ "duration": 0,
4522
4600
  "state": "passed",
4523
4601
  "speed": "fast",
4524
4602
  "pass": true,
@@ -4527,28 +4605,28 @@
4527
4605
  "context": null,
4528
4606
  "code": "return __awaiter(this, void 0, void 0, function* () {\n const result = yield getParamters({\n hosts: ['192.168.178.2', '192.168.178.3'],\n id: '****',\n protocol: NodePyATVProtocol.mrp,\n dmapCredentials: '****',\n mrpCredentials: '****',\n airplayCredentials: '****',\n companionCredentials: '1234',\n raopCredentials: '::foo:'\n });\n assert.deepEqual(result, [\n '-s', '192.168.178.2,192.168.178.3',\n '-i', '****',\n '--protocol', 'mrp',\n '--dmap-credentials', '****',\n '--mrp-credentials', '****',\n '--airplay-credentials', '****',\n '--companion-credentials', '1234',\n '--raop-credentials', '::foo:'\n ]);\n});",
4529
4607
  "err": {},
4530
- "uuid": "7a7f60f9-26dc-474a-a7ce-679c6a72b0fd",
4531
- "parentUUID": "19ba22a7-fa3c-4736-9cd3-66f598927824",
4608
+ "uuid": "6d11748d-3abc-4179-9e98-649d928037fe",
4609
+ "parentUUID": "e311694b-9c19-487d-8ecc-e555af5cdf4f",
4532
4610
  "isHook": false,
4533
4611
  "skipped": false
4534
4612
  }
4535
4613
  ],
4536
4614
  "suites": [],
4537
4615
  "passes": [
4538
- "b6d82914-51b0-4abb-b9c2-6f6f1732a841",
4539
- "b8ecc261-918f-4045-aecc-50e6dc52805a",
4540
- "7a7f60f9-26dc-474a-a7ce-679c6a72b0fd"
4616
+ "b4fde6b3-fa93-4c70-b4da-4d489c705144",
4617
+ "a695f5ec-f5b1-4e08-9097-2bd41a6cbed0",
4618
+ "6d11748d-3abc-4179-9e98-649d928037fe"
4541
4619
  ],
4542
4620
  "failures": [],
4543
4621
  "pending": [],
4544
4622
  "skipped": [],
4545
- "duration": 1,
4623
+ "duration": 0,
4546
4624
  "root": false,
4547
4625
  "rootEmpty": false,
4548
4626
  "_timeout": 2000
4549
4627
  },
4550
4628
  {
4551
- "uuid": "cf9d8e1b-a8c8-45ef-99ac-8f888212a451",
4629
+ "uuid": "e2cae283-0ba3-4dca-a2bd-02f082d431fa",
4552
4630
  "title": "parseState()",
4553
4631
  "fullFile": "/home/runner/work/node-pyatv/node-pyatv/test/tools.ts",
4554
4632
  "file": "/test/tools.ts",
@@ -4568,8 +4646,8 @@
4568
4646
  "context": null,
4569
4647
  "code": "const input = {};\nconst result = parseState(input, '', {});\nassert.deepStrictEqual(result, {\n dateTime: null,\n hash: null,\n mediaType: null,\n deviceState: null,\n title: null,\n artist: null,\n album: null,\n genre: null,\n totalTime: null,\n position: null,\n shuffle: null,\n repeat: null,\n app: null,\n appId: null,\n powerState: null\n});",
4570
4648
  "err": {},
4571
- "uuid": "31f848bd-9bc9-4a01-9108-a76daaab92bc",
4572
- "parentUUID": "cf9d8e1b-a8c8-45ef-99ac-8f888212a451",
4649
+ "uuid": "5600e3a6-4120-4de6-8733-56272c318163",
4650
+ "parentUUID": "e2cae283-0ba3-4dca-a2bd-02f082d431fa",
4573
4651
  "isHook": false,
4574
4652
  "skipped": false
4575
4653
  },
@@ -4586,8 +4664,8 @@
4586
4664
  "context": null,
4587
4665
  "code": "// @ts-ignore\nconst result = parseState(null, '', {});\nassert.deepStrictEqual(result, {\n dateTime: null,\n hash: null,\n mediaType: null,\n deviceState: null,\n title: null,\n artist: null,\n album: null,\n genre: null,\n totalTime: null,\n position: null,\n shuffle: null,\n repeat: null,\n app: null,\n appId: null,\n powerState: null\n});",
4588
4666
  "err": {},
4589
- "uuid": "4f2e7df2-b346-44b5-8859-e36d4d1d598f",
4590
- "parentUUID": "cf9d8e1b-a8c8-45ef-99ac-8f888212a451",
4667
+ "uuid": "bf37377f-a22a-4e20-802f-3b8b30ed2166",
4668
+ "parentUUID": "e2cae283-0ba3-4dca-a2bd-02f082d431fa",
4591
4669
  "isHook": false,
4592
4670
  "skipped": false
4593
4671
  },
@@ -4604,8 +4682,8 @@
4604
4682
  "context": null,
4605
4683
  "code": "const input = {\n result: 'success',\n datetime: '2020-11-07T22:38:43.608030+01:00',\n hash: '100e0ab6-6ff5-4199-9c04-a7107ff78712',\n media_type: 'video',\n device_state: 'playing',\n title: 'Solo: A Star Wars Story',\n artist: null,\n album: null,\n genre: null,\n total_time: 8097,\n position: 27,\n shuffle: 'off',\n repeat: 'off',\n app: 'Disney+',\n app_id: 'com.disney.disneyplus',\n powerState: null\n};\nconst result = parseState(input, '', {});\nassert.deepStrictEqual(result, {\n dateTime: new Date('2020-11-07T22:38:43.608030+01:00'),\n hash: '100e0ab6-6ff5-4199-9c04-a7107ff78712',\n mediaType: NodePyATVMediaType.video,\n deviceState: NodePyATVDeviceState.playing,\n title: 'Solo: A Star Wars Story',\n artist: null,\n album: null,\n genre: null,\n totalTime: 8097,\n position: 27,\n shuffle: NodePyATVShuffleState.off,\n repeat: NodePyATVRepeatState.off,\n app: 'Disney+',\n appId: 'com.disney.disneyplus',\n powerState: null\n});",
4606
4684
  "err": {},
4607
- "uuid": "13566cd7-e55f-4cbb-bc99-4380c2227917",
4608
- "parentUUID": "cf9d8e1b-a8c8-45ef-99ac-8f888212a451",
4685
+ "uuid": "7073e94e-c466-4e13-8aaf-27e82ad71ebf",
4686
+ "parentUUID": "e2cae283-0ba3-4dca-a2bd-02f082d431fa",
4609
4687
  "isHook": false,
4610
4688
  "skipped": false
4611
4689
  },
@@ -4613,7 +4691,7 @@
4613
4691
  "title": "should throw an error for pyatv exceptions",
4614
4692
  "fullTitle": "Tools parseState() should throw an error for pyatv exceptions",
4615
4693
  "timedOut": false,
4616
- "duration": 1,
4694
+ "duration": 0,
4617
4695
  "state": "passed",
4618
4696
  "speed": "fast",
4619
4697
  "pass": true,
@@ -4622,8 +4700,8 @@
4622
4700
  "context": null,
4623
4701
  "code": "const input = {\n result: 'failure',\n datetime: '2021-11-24T21:13:36.424576+03:00',\n exception: 'invalid credentials: 321',\n stacktrace: 'Traceback (most recent call last):\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/scripts/atvscript.py\\\", line 302, in appstart\\n print(args.output(await _handle_command(args, abort_sem, loop)), flush=True)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/scripts/atvscript.py\\\", line 196, in _handle_command\\n atv = await connect(config, loop, protocol=Protocol.MRP)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/__init__.py\\\", line 96, in connect\\n for setup_data in proto_methods.setup(\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/protocols/airplay/__init__.py\\\", line 192, in setup\\n stream = AirPlayStream(config, service)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/protocols/airplay/__init__.py\\\", line 79, in __init__\\n self._credentials: HapCredentials = parse_credentials(self.service.credentials)\\n File \\\"/Users/free/Library/Python/3.8/lib/python/site-packages/pyatv/auth/hap_pairing.py\\\", line 139, in parse_credentials\\n raise exceptions.InvalidCredentialsError(\\\"invalid credentials: \\\" + detail_string)\\npyatv.exceptions.InvalidCredentialsError: invalid credentials: 321\\n'\n};\nassert.throws(() => {\n parseState(input, '', {});\n}, /Got pyatv Error: invalid credentials: 321/);",
4624
4702
  "err": {},
4625
- "uuid": "0bfb25b8-5b93-4997-b948-dfcd5ddc17a2",
4626
- "parentUUID": "cf9d8e1b-a8c8-45ef-99ac-8f888212a451",
4703
+ "uuid": "1bb5ab89-ceb1-43c9-9b27-230fa4c4ece2",
4704
+ "parentUUID": "e2cae283-0ba3-4dca-a2bd-02f082d431fa",
4627
4705
  "isHook": false,
4628
4706
  "skipped": false
4629
4707
  },
@@ -4640,8 +4718,8 @@
4640
4718
  "context": null,
4641
4719
  "code": "const input = { datetime: 'today' };\nconst result = parseState(input, '', {});\nassert.deepStrictEqual(result, {\n dateTime: null,\n hash: null,\n mediaType: null,\n deviceState: null,\n title: null,\n artist: null,\n album: null,\n genre: null,\n totalTime: null,\n position: null,\n shuffle: null,\n repeat: null,\n app: null,\n appId: null,\n powerState: null\n});",
4642
4720
  "err": {},
4643
- "uuid": "64763510-5eea-407f-a904-8f1356214160",
4644
- "parentUUID": "cf9d8e1b-a8c8-45ef-99ac-8f888212a451",
4721
+ "uuid": "187c27c8-1a45-4563-bad3-005c8a8a742a",
4722
+ "parentUUID": "e2cae283-0ba3-4dca-a2bd-02f082d431fa",
4645
4723
  "isHook": false,
4646
4724
  "skipped": false
4647
4725
  },
@@ -4658,8 +4736,8 @@
4658
4736
  "context": null,
4659
4737
  "code": "const input = {\n result: 'success',\n datetime: true,\n hash: 1337,\n media_type: false,\n device_state: 43,\n title: undefined,\n artist: 90,\n album: Infinity,\n genre: Math.PI,\n total_time: '23min',\n position: '0:30.123',\n shuffle: false,\n repeat: true,\n app: 0,\n app_id: 891645381647289,\n powerState: null\n};\nconst result = parseState(input, '', {});\nassert.deepStrictEqual(result, {\n dateTime: null,\n hash: null,\n mediaType: null,\n deviceState: null,\n title: null,\n artist: null,\n album: null,\n genre: null,\n totalTime: null,\n position: null,\n shuffle: null,\n repeat: null,\n app: null,\n appId: null,\n powerState: null\n});",
4660
4738
  "err": {},
4661
- "uuid": "7986eaa1-8909-4131-a25a-a83b1e4eab30",
4662
- "parentUUID": "cf9d8e1b-a8c8-45ef-99ac-8f888212a451",
4739
+ "uuid": "7b8c11af-0ea8-455a-b543-d5a1f3c6340c",
4740
+ "parentUUID": "e2cae283-0ba3-4dca-a2bd-02f082d431fa",
4663
4741
  "isHook": false,
4664
4742
  "skipped": false
4665
4743
  },
@@ -4676,26 +4754,26 @@
4676
4754
  "context": null,
4677
4755
  "code": "const input = {\n media_type: '3d-experience',\n device_state: 'initiating',\n shuffle: 'everything',\n repeat: 'nothing'\n};\nconst result = parseState(input, '', {});\nassert.deepStrictEqual(result, {\n dateTime: null,\n hash: null,\n mediaType: null,\n deviceState: null,\n title: null,\n artist: null,\n album: null,\n genre: null,\n totalTime: null,\n position: null,\n shuffle: null,\n repeat: null,\n app: null,\n appId: null,\n powerState: null\n});",
4678
4756
  "err": {},
4679
- "uuid": "db302c23-9bcb-46a6-bfaa-9af0d7cefc3b",
4680
- "parentUUID": "cf9d8e1b-a8c8-45ef-99ac-8f888212a451",
4757
+ "uuid": "cf8610ed-49b2-47ee-b7fc-3e040de13918",
4758
+ "parentUUID": "e2cae283-0ba3-4dca-a2bd-02f082d431fa",
4681
4759
  "isHook": false,
4682
4760
  "skipped": false
4683
4761
  }
4684
4762
  ],
4685
4763
  "suites": [],
4686
4764
  "passes": [
4687
- "31f848bd-9bc9-4a01-9108-a76daaab92bc",
4688
- "4f2e7df2-b346-44b5-8859-e36d4d1d598f",
4689
- "13566cd7-e55f-4cbb-bc99-4380c2227917",
4690
- "0bfb25b8-5b93-4997-b948-dfcd5ddc17a2",
4691
- "64763510-5eea-407f-a904-8f1356214160",
4692
- "7986eaa1-8909-4131-a25a-a83b1e4eab30",
4693
- "db302c23-9bcb-46a6-bfaa-9af0d7cefc3b"
4765
+ "5600e3a6-4120-4de6-8733-56272c318163",
4766
+ "bf37377f-a22a-4e20-802f-3b8b30ed2166",
4767
+ "7073e94e-c466-4e13-8aaf-27e82ad71ebf",
4768
+ "1bb5ab89-ceb1-43c9-9b27-230fa4c4ece2",
4769
+ "187c27c8-1a45-4563-bad3-005c8a8a742a",
4770
+ "7b8c11af-0ea8-455a-b543-d5a1f3c6340c",
4771
+ "cf8610ed-49b2-47ee-b7fc-3e040de13918"
4694
4772
  ],
4695
4773
  "failures": [],
4696
4774
  "pending": [],
4697
4775
  "skipped": [],
4698
- "duration": 1,
4776
+ "duration": 0,
4699
4777
  "root": false,
4700
4778
  "rootEmpty": false,
4701
4779
  "_timeout": 2000