Merge ~sylvain-pineau/checkbox-support:fix-1827826 into checkbox-support:master
- Git
- lp:~sylvain-pineau/checkbox-support
- fix-1827826
- Merge into master
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Sylvain Pineau | ||||
Approved revision: | 169d2be77082fc1ba6864f10a5402129894d15b5 | ||||
Merged at revision: | 3907bd028b0f420c204874b1fb0631feb683d2cc | ||||
Proposed branch: | ~sylvain-pineau/checkbox-support:fix-1827826 | ||||
Merge into: | checkbox-support:master | ||||
Diff against target: |
683 lines (+637/-3) 3 files modified
checkbox_support/parsers/pactl.py (+8/-3) checkbox_support/parsers/tests/pactl_data/pa_ucm_pre_tag_bionic.txt (+619/-0) checkbox_support/parsers/tests/test_pactl.py (+10/-0) |
||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Devices Certification Bot | Needs Fixing | ||
Sylvain Pineau (community) | Approve | ||
Review via email: mp+367029@code.launchpad.net |
Commit message
Description of the change
Fixes linked bug (update of the pactl parser)
Devices Certification Bot (ce-certification-qa) wrote : | # |
The merge was fine but running tests failed.
[xenial] [10:21:33] starting container
Device project added to xenial-testing
[xenial] [10:21:44] provisioning container
[trusty] [10:21:52] starting container
[bionic] [10:21:53] starting container
Device project added to trusty-testing
Device project added to bionic-testing
[trusty] [10:22:06] provisioning container
[bionic] [10:22:07] provisioning container
[trusty] [10:24:07] Unable to provision requirements in container!
[bionic] [10:24:07] Unable to provision requirements in container!
[trusty] output: https:/
[trusty] [10:24:10] Fixing file permissions in source directory
[bionic] output: https:/
[bionic] [10:24:10] Fixing file permissions in source directory
[bionic] Destroying failed container to reclaim resources
[trusty] Destroying failed container to reclaim resources
[xenial] [10:24:24] Unable to provision requirements in container!
[xenial] output: https:/
[xenial] [10:24:26] Fixing file permissions in source directory
[xenial] Destroying failed container to reclaim resources
Devices Certification Bot (ce-certification-qa) wrote : | # |
The merge was fine but running tests failed.
[bionic] [10:51:32] starting container
[trusty] [10:51:32] starting container
Device project added to bionic-testing
Device project added to trusty-testing
[xenial] [10:51:35] starting container
Device project added to xenial-testing
[bionic] [10:51:48] provisioning container
[trusty] [10:51:49] provisioning container
[xenial] [10:51:49] provisioning container
[bionic] [10:51:56] Unable to provision requirements in container!
[bionic] output: https:/
[bionic] [10:51:59] Fixing file permissions in source directory
[bionic] Destroying failed container to reclaim resources
[xenial] [10:52:10] Starting tests...
[xenial] Found a test script: ./requirements/
[trusty] [10:52:29] Starting tests...
[trusty] Found a test script: ./requirements/
[xenial] [10:52:39] container-
[xenial] [10:52:39] Fixing file permissions in source directory
[xenial] [10:52:39] Destroying container
[trusty] [10:52:54] container-
[trusty] [10:52:54] Fixing file permissions in source directory
[trusty] [10:52:54] Destroying container
Preview Diff
1 | diff --git a/checkbox_support/parsers/pactl.py b/checkbox_support/parsers/pactl.py | |||
2 | index 928e2e5..0d8e227 100644 | |||
3 | --- a/checkbox_support/parsers/pactl.py | |||
4 | +++ b/checkbox_support/parsers/pactl.py | |||
5 | @@ -1,8 +1,9 @@ | |||
6 | 1 | # This file is part of Checkbox. | 1 | # This file is part of Checkbox. |
7 | 2 | # | 2 | # |
9 | 3 | # Copyright 2013 Canonical Ltd. | 3 | # Copyright 2013-2019 Canonical Ltd. |
10 | 4 | # Written by: | 4 | # Written by: |
11 | 5 | # Zygmunt Krynicki <zygmunt.krynicki@canonical.com> | 5 | # Zygmunt Krynicki <zygmunt.krynicki@canonical.com> |
12 | 6 | # Sylvain Pineau <sylvain.pineau@canonical.com> | ||
13 | 6 | # | 7 | # |
14 | 7 | # Checkbox is free software: you can redistribute it and/or modify | 8 | # Checkbox is free software: you can redistribute it and/or modify |
15 | 8 | # it under the terms of the GNU General Public License version 3, | 9 | # it under the terms of the GNU General Public License version 3, |
16 | @@ -220,7 +221,9 @@ class Port(Node): | |||
17 | 220 | } | 221 | } |
18 | 221 | 222 | ||
19 | 222 | __syntax__ = ( | 223 | __syntax__ = ( |
21 | 223 | p.Word(p.alphanums + "-;").setResultsName('port-name') | 224 | p.Optional('[Out] ').suppress() |
22 | 225 | + p.Optional('[In] ').suppress() | ||
23 | 226 | + p.Word(p.alphanums + "-;").setResultsName('port-name') | ||
24 | 224 | + p.Suppress(':') | 227 | + p.Suppress(':') |
25 | 225 | # This part was very tricky to write. The label is basically | 228 | # This part was very tricky to write. The label is basically |
26 | 226 | # arbitrary localized Unicode text. We want to grab all of it in | 229 | # arbitrary localized Unicode text. We want to grab all of it in |
27 | @@ -283,7 +286,9 @@ class PortWithProfile(Node): | |||
28 | 283 | } | 286 | } |
29 | 284 | 287 | ||
30 | 285 | __syntax__ = ( | 288 | __syntax__ = ( |
32 | 286 | p.Word(p.alphanums + "-;").setResultsName('port-name') | 289 | p.Optional('[Out] ').suppress() |
33 | 290 | + p.Optional('[In] ').suppress() | ||
34 | 291 | + p.Word(p.alphanums + "-;").setResultsName('port-name') | ||
35 | 287 | + p.Suppress(':') | 292 | + p.Suppress(':') |
36 | 288 | # This part was very tricky to write. The label is basically arbitrary | 293 | # This part was very tricky to write. The label is basically arbitrary |
37 | 289 | # localized Unicode text. We want to grab all of it in one go but | 294 | # localized Unicode text. We want to grab all of it in one go but |
38 | diff --git a/checkbox_support/parsers/tests/pactl_data/pa_ucm_pre_tag_bionic.txt b/checkbox_support/parsers/tests/pactl_data/pa_ucm_pre_tag_bionic.txt | |||
39 | 290 | new file mode 100644 | 295 | new file mode 100644 |
40 | index 0000000..1b67e20 | |||
41 | --- /dev/null | |||
42 | +++ b/checkbox_support/parsers/tests/pactl_data/pa_ucm_pre_tag_bionic.txt | |||
43 | @@ -0,0 +1,619 @@ | |||
44 | 1 | Module #0 | ||
45 | 2 | Name: module-device-restore | ||
46 | 3 | Argument: | ||
47 | 4 | Usage counter: n/a | ||
48 | 5 | Properties: | ||
49 | 6 | module.author = "Lennart Poettering" | ||
50 | 7 | module.description = "Automatically restore the volume/mute state of devices" | ||
51 | 8 | module.version = "11.1" | ||
52 | 9 | |||
53 | 10 | Module #1 | ||
54 | 11 | Name: module-stream-restore | ||
55 | 12 | Argument: | ||
56 | 13 | Usage counter: n/a | ||
57 | 14 | Properties: | ||
58 | 15 | module.author = "Lennart Poettering" | ||
59 | 16 | module.description = "Automatically restore the volume/mute/device state of streams" | ||
60 | 17 | module.version = "11.1" | ||
61 | 18 | |||
62 | 19 | Module #2 | ||
63 | 20 | Name: module-card-restore | ||
64 | 21 | Argument: | ||
65 | 22 | Usage counter: n/a | ||
66 | 23 | Properties: | ||
67 | 24 | module.author = "Lennart Poettering" | ||
68 | 25 | module.description = "Automatically restore profile of cards" | ||
69 | 26 | module.version = "11.1" | ||
70 | 27 | |||
71 | 28 | Module #3 | ||
72 | 29 | Name: module-augment-properties | ||
73 | 30 | Argument: | ||
74 | 31 | Usage counter: n/a | ||
75 | 32 | Properties: | ||
76 | 33 | module.author = "Lennart Poettering" | ||
77 | 34 | module.description = "Augment the property sets of streams with additional static information" | ||
78 | 35 | module.version = "11.1" | ||
79 | 36 | |||
80 | 37 | Module #4 | ||
81 | 38 | Name: module-switch-on-port-available | ||
82 | 39 | Argument: | ||
83 | 40 | Usage counter: n/a | ||
84 | 41 | Properties: | ||
85 | 42 | |||
86 | 43 | |||
87 | 44 | Module #5 | ||
88 | 45 | Name: module-switch-on-connect | ||
89 | 46 | Argument: | ||
90 | 47 | Usage counter: n/a | ||
91 | 48 | Properties: | ||
92 | 49 | module.author = "Michael Terry" | ||
93 | 50 | module.description = "When a sink/source is added, switch to it or conditionally switch to it" | ||
94 | 51 | module.version = "11.1" | ||
95 | 52 | |||
96 | 53 | Module #6 | ||
97 | 54 | Name: module-udev-detect | ||
98 | 55 | Argument: | ||
99 | 56 | Usage counter: n/a | ||
100 | 57 | Properties: | ||
101 | 58 | module.author = "Lennart Poettering" | ||
102 | 59 | module.description = "Detect available audio hardware and load matching drivers" | ||
103 | 60 | module.version = "11.1" | ||
104 | 61 | |||
105 | 62 | Module #7 | ||
106 | 63 | Name: module-alsa-card | ||
107 | 64 | Argument: device_id="0" name="pci-0000_00_1f.3-platform-skl_hda_dsp_generic" card_name="alsa_card.pci-0000_00_1f.3-platform-skl_hda_dsp_generic" namereg_fail=false tsched=yes fixed_latency_range=no ignore_dB=no deferred_volume=yes use_ucm=yes card_properties="module-udev-detect.discovered=1" | ||
108 | 65 | Usage counter: 0 | ||
109 | 66 | Properties: | ||
110 | 67 | module.author = "Lennart Poettering" | ||
111 | 68 | module.description = "ALSA Card" | ||
112 | 69 | module.version = "11.1" | ||
113 | 70 | |||
114 | 71 | Module #8 | ||
115 | 72 | Name: module-bluetooth-policy | ||
116 | 73 | Argument: | ||
117 | 74 | Usage counter: n/a | ||
118 | 75 | Properties: | ||
119 | 76 | module.author = "Frédéric Dalleau, Pali Rohár" | ||
120 | 77 | module.description = "Policy module to make using bluetooth devices out-of-the-box easier" | ||
121 | 78 | module.version = "11.1" | ||
122 | 79 | |||
123 | 80 | Module #9 | ||
124 | 81 | Name: module-bluetooth-discover | ||
125 | 82 | Argument: | ||
126 | 83 | Usage counter: n/a | ||
127 | 84 | Properties: | ||
128 | 85 | module.author = "João Paulo Rechi Vita" | ||
129 | 86 | module.description = "Detect available Bluetooth daemon and load the corresponding discovery module" | ||
130 | 87 | module.version = "11.1" | ||
131 | 88 | |||
132 | 89 | Module #10 | ||
133 | 90 | Name: module-bluez5-discover | ||
134 | 91 | Argument: | ||
135 | 92 | Usage counter: n/a | ||
136 | 93 | Properties: | ||
137 | 94 | module.author = "João Paulo Rechi Vita" | ||
138 | 95 | module.description = "Detect available BlueZ 5 Bluetooth audio devices and load BlueZ 5 Bluetooth audio drivers" | ||
139 | 96 | module.version = "11.1" | ||
140 | 97 | |||
141 | 98 | Module #11 | ||
142 | 99 | Name: module-native-protocol-unix | ||
143 | 100 | Argument: | ||
144 | 101 | Usage counter: n/a | ||
145 | 102 | Properties: | ||
146 | 103 | module.author = "Lennart Poettering" | ||
147 | 104 | module.description = "Native protocol (UNIX sockets)" | ||
148 | 105 | module.version = "11.1" | ||
149 | 106 | |||
150 | 107 | Module #12 | ||
151 | 108 | Name: module-default-device-restore | ||
152 | 109 | Argument: | ||
153 | 110 | Usage counter: n/a | ||
154 | 111 | Properties: | ||
155 | 112 | module.author = "Lennart Poettering" | ||
156 | 113 | module.description = "Automatically restore the default sink and source" | ||
157 | 114 | module.version = "11.1" | ||
158 | 115 | |||
159 | 116 | Module #13 | ||
160 | 117 | Name: module-rescue-streams | ||
161 | 118 | Argument: | ||
162 | 119 | Usage counter: n/a | ||
163 | 120 | Properties: | ||
164 | 121 | module.author = "Lennart Poettering" | ||
165 | 122 | module.description = "When a sink/source is removed, try to move its streams to the default sink/source" | ||
166 | 123 | module.version = "11.1" | ||
167 | 124 | |||
168 | 125 | Module #14 | ||
169 | 126 | Name: module-always-sink | ||
170 | 127 | Argument: | ||
171 | 128 | Usage counter: n/a | ||
172 | 129 | Properties: | ||
173 | 130 | module.author = "Colin Guthrie" | ||
174 | 131 | module.description = "Always keeps at least one sink loaded even if it's a null one" | ||
175 | 132 | module.version = "11.1" | ||
176 | 133 | |||
177 | 134 | Module #15 | ||
178 | 135 | Name: module-intended-roles | ||
179 | 136 | Argument: | ||
180 | 137 | Usage counter: n/a | ||
181 | 138 | Properties: | ||
182 | 139 | module.author = "Lennart Poettering" | ||
183 | 140 | module.description = "Automatically set device of streams based on intended roles of devices" | ||
184 | 141 | module.version = "11.1" | ||
185 | 142 | |||
186 | 143 | Module #16 | ||
187 | 144 | Name: module-suspend-on-idle | ||
188 | 145 | Argument: | ||
189 | 146 | Usage counter: n/a | ||
190 | 147 | Properties: | ||
191 | 148 | module.author = "Lennart Poettering" | ||
192 | 149 | module.description = "When a sink/source is idle for too long, suspend it" | ||
193 | 150 | module.version = "11.1" | ||
194 | 151 | |||
195 | 152 | Module #17 | ||
196 | 153 | Name: module-console-kit | ||
197 | 154 | Argument: | ||
198 | 155 | Usage counter: n/a | ||
199 | 156 | Properties: | ||
200 | 157 | module.author = "Lennart Poettering" | ||
201 | 158 | module.description = "Create a client for each ConsoleKit session of this user" | ||
202 | 159 | module.version = "11.1" | ||
203 | 160 | |||
204 | 161 | Module #18 | ||
205 | 162 | Name: module-systemd-login | ||
206 | 163 | Argument: | ||
207 | 164 | Usage counter: n/a | ||
208 | 165 | Properties: | ||
209 | 166 | module.author = "Lennart Poettering" | ||
210 | 167 | module.description = "Create a client for each login session of this user" | ||
211 | 168 | module.version = "11.1" | ||
212 | 169 | |||
213 | 170 | Module #19 | ||
214 | 171 | Name: module-position-event-sounds | ||
215 | 172 | Argument: | ||
216 | 173 | Usage counter: n/a | ||
217 | 174 | Properties: | ||
218 | 175 | module.author = "Lennart Poettering" | ||
219 | 176 | module.description = "Position event sounds between L and R depending on the position on screen of the widget triggering them." | ||
220 | 177 | module.version = "11.1" | ||
221 | 178 | |||
222 | 179 | Module #20 | ||
223 | 180 | Name: module-role-cork | ||
224 | 181 | Argument: | ||
225 | 182 | Usage counter: n/a | ||
226 | 183 | Properties: | ||
227 | 184 | module.author = "Lennart Poettering" | ||
228 | 185 | module.description = "Mute & cork streams with certain roles while others exist" | ||
229 | 186 | module.version = "11.1" | ||
230 | 187 | |||
231 | 188 | Module #21 | ||
232 | 189 | Name: module-filter-heuristics | ||
233 | 190 | Argument: | ||
234 | 191 | Usage counter: n/a | ||
235 | 192 | Properties: | ||
236 | 193 | module.author = "Colin Guthrie" | ||
237 | 194 | module.description = "Detect when various filters are desirable" | ||
238 | 195 | module.version = "11.1" | ||
239 | 196 | |||
240 | 197 | Module #22 | ||
241 | 198 | Name: module-filter-apply | ||
242 | 199 | Argument: | ||
243 | 200 | Usage counter: n/a | ||
244 | 201 | Properties: | ||
245 | 202 | module.author = "Colin Guthrie" | ||
246 | 203 | module.description = "Load filter sinks automatically when needed" | ||
247 | 204 | module.version = "11.1" | ||
248 | 205 | |||
249 | 206 | Module #23 | ||
250 | 207 | Name: module-x11-publish | ||
251 | 208 | Argument: display=:0 | ||
252 | 209 | Usage counter: n/a | ||
253 | 210 | Properties: | ||
254 | 211 | module.author = "Lennart Poettering" | ||
255 | 212 | module.description = "X11 credential publisher" | ||
256 | 213 | module.version = "11.1" | ||
257 | 214 | |||
258 | 215 | Module #24 | ||
259 | 216 | Name: module-x11-bell | ||
260 | 217 | Argument: display=:0 sample=bell.ogg | ||
261 | 218 | Usage counter: n/a | ||
262 | 219 | Properties: | ||
263 | 220 | module.author = "Lennart Poettering" | ||
264 | 221 | module.description = "X11 bell interceptor" | ||
265 | 222 | module.version = "11.1" | ||
266 | 223 | |||
267 | 224 | Module #25 | ||
268 | 225 | Name: module-x11-cork-request | ||
269 | 226 | Argument: display=:0 | ||
270 | 227 | Usage counter: n/a | ||
271 | 228 | Properties: | ||
272 | 229 | module.author = "Lennart Poettering" | ||
273 | 230 | module.description = "Synthesize X11 media key events when cork/uncork is requested" | ||
274 | 231 | module.version = "11.1" | ||
275 | 232 | |||
276 | 233 | Module #26 | ||
277 | 234 | Name: module-x11-xsmp | ||
278 | 235 | Argument: display=:0 session_manager=local/test-Inspiron-5490:@/tmp/.ICE-unix/2115,unix/test-Inspiron-5490:/tmp/.ICE-unix/2115 | ||
279 | 236 | Usage counter: n/a | ||
280 | 237 | Properties: | ||
281 | 238 | module.author = "Lennart Poettering" | ||
282 | 239 | module.description = "X11 session management" | ||
283 | 240 | module.version = "11.1" | ||
284 | 241 | |||
285 | 242 | Sink #0 | ||
286 | 243 | State: SUSPENDED | ||
287 | 244 | Name: alsa_output.pci-0000_00_1f.3-platform-skl_hda_dsp_generic.HiFi__hw_sofsklhdacard_0__sink | ||
288 | 245 | Description: sof-skl_hda_card Speaker + Headphone | ||
289 | 246 | Driver: module-alsa-card.c | ||
290 | 247 | Sample Specification: s16le 2ch 48000Hz | ||
291 | 248 | Channel Map: front-left,front-right | ||
292 | 249 | Owner Module: 7 | ||
293 | 250 | Mute: no | ||
294 | 251 | Volume: front-left: 65536 / 100% / 0.00 dB, front-right: 65536 / 100% / 0.00 dB | ||
295 | 252 | balance 0.00 | ||
296 | 253 | Base Volume: 65536 / 100% / 0.00 dB | ||
297 | 254 | Monitor Source: alsa_output.pci-0000_00_1f.3-platform-skl_hda_dsp_generic.HiFi__hw_sofsklhdacard_0__sink.monitor | ||
298 | 255 | Latency: 0 usec, configured 0 usec | ||
299 | 256 | Flags: HARDWARE DECIBEL_VOLUME LATENCY | ||
300 | 257 | Properties: | ||
301 | 258 | alsa.resolution_bits = "16" | ||
302 | 259 | device.api = "alsa" | ||
303 | 260 | device.class = "sound" | ||
304 | 261 | alsa.class = "generic" | ||
305 | 262 | alsa.subclass = "generic-mix" | ||
306 | 263 | alsa.name = "" | ||
307 | 264 | alsa.id = "HDA Analog (*)" | ||
308 | 265 | alsa.subdevice = "0" | ||
309 | 266 | alsa.subdevice_name = "subdevice #0" | ||
310 | 267 | alsa.device = "0" | ||
311 | 268 | alsa.card = "0" | ||
312 | 269 | alsa.card_name = "sof-skl_hda_card" | ||
313 | 270 | alsa.long_card_name = "DellInc.-Inspiron5490--" | ||
314 | 271 | alsa.driver_name = "snd_soc_skl_hda_dsp" | ||
315 | 272 | device.bus_path = "pci-0000:00:1f.3-platform-skl_hda_dsp_generic" | ||
316 | 273 | sysfs.path = "/devices/pci0000:00/0000:00:1f.3/skl_hda_dsp_generic/sound/card0" | ||
317 | 274 | device.bus = "pci" | ||
318 | 275 | device.vendor.id = "8086" | ||
319 | 276 | device.vendor.name = "Intel Corporation" | ||
320 | 277 | device.product.id = "9dc8" | ||
321 | 278 | device.string = "hw:sofsklhdacard,0" | ||
322 | 279 | device.buffering.buffer_size = "65472" | ||
323 | 280 | device.buffering.fragment_size = "16320" | ||
324 | 281 | device.access_mode = "mmap+timer" | ||
325 | 282 | device.profile.name = "HiFi: hw:sofsklhdacard,0: sink" | ||
326 | 283 | device.profile.description = "Speaker + Headphone" | ||
327 | 284 | device.description = "sof-skl_hda_card Speaker + Headphone" | ||
328 | 285 | module-udev-detect.discovered = "1" | ||
329 | 286 | device.icon_name = "audio-card-pci" | ||
330 | 287 | Ports: | ||
331 | 288 | [Out] Speaker: Speaker (priority: 100, not available) | ||
332 | 289 | [Out] Headphone: Headphone (priority: 100, available) | ||
333 | 290 | Active Port: [Out] Headphone | ||
334 | 291 | Formats: | ||
335 | 292 | pcm | ||
336 | 293 | |||
337 | 294 | Source #0 | ||
338 | 295 | State: SUSPENDED | ||
339 | 296 | Name: alsa_output.pci-0000_00_1f.3-platform-skl_hda_dsp_generic.HiFi__hw_sofsklhdacard_0__sink.monitor | ||
340 | 297 | Description: Monitor of sof-skl_hda_card Speaker + Headphone | ||
341 | 298 | Driver: module-alsa-card.c | ||
342 | 299 | Sample Specification: s16le 2ch 48000Hz | ||
343 | 300 | Channel Map: front-left,front-right | ||
344 | 301 | Owner Module: 7 | ||
345 | 302 | Mute: no | ||
346 | 303 | Volume: front-left: 65536 / 100% / 0.00 dB, front-right: 65536 / 100% / 0.00 dB | ||
347 | 304 | balance 0.00 | ||
348 | 305 | Base Volume: 65536 / 100% / 0.00 dB | ||
349 | 306 | Monitor of Sink: alsa_output.pci-0000_00_1f.3-platform-skl_hda_dsp_generic.HiFi__hw_sofsklhdacard_0__sink | ||
350 | 307 | Latency: 0 usec, configured 0 usec | ||
351 | 308 | Flags: DECIBEL_VOLUME LATENCY | ||
352 | 309 | Properties: | ||
353 | 310 | device.description = "Monitor of sof-skl_hda_card Speaker + Headphone" | ||
354 | 311 | device.class = "monitor" | ||
355 | 312 | alsa.card = "0" | ||
356 | 313 | alsa.card_name = "sof-skl_hda_card" | ||
357 | 314 | alsa.long_card_name = "DellInc.-Inspiron5490--" | ||
358 | 315 | alsa.driver_name = "snd_soc_skl_hda_dsp" | ||
359 | 316 | device.bus_path = "pci-0000:00:1f.3-platform-skl_hda_dsp_generic" | ||
360 | 317 | sysfs.path = "/devices/pci0000:00/0000:00:1f.3/skl_hda_dsp_generic/sound/card0" | ||
361 | 318 | device.bus = "pci" | ||
362 | 319 | device.vendor.id = "8086" | ||
363 | 320 | device.vendor.name = "Intel Corporation" | ||
364 | 321 | device.product.id = "9dc8" | ||
365 | 322 | device.string = "0" | ||
366 | 323 | module-udev-detect.discovered = "1" | ||
367 | 324 | device.icon_name = "audio-card-pci" | ||
368 | 325 | Formats: | ||
369 | 326 | pcm | ||
370 | 327 | |||
371 | 328 | Source #1 | ||
372 | 329 | State: SUSPENDED | ||
373 | 330 | Name: alsa_input.pci-0000_00_1f.3-platform-skl_hda_dsp_generic.HiFi__hw_sofsklhdacard_6__source | ||
374 | 331 | Description: sof-skl_hda_card Digital Micrphone | ||
375 | 332 | Driver: module-alsa-card.c | ||
376 | 333 | Sample Specification: s16le 2ch 48000Hz | ||
377 | 334 | Channel Map: front-left,front-right | ||
378 | 335 | Owner Module: 7 | ||
379 | 336 | Mute: no | ||
380 | 337 | Volume: front-left: 65536 / 100% / 0.00 dB, front-right: 65536 / 100% / 0.00 dB | ||
381 | 338 | balance 0.00 | ||
382 | 339 | Base Volume: 65536 / 100% / 0.00 dB | ||
383 | 340 | Monitor of Sink: n/a | ||
384 | 341 | Latency: 0 usec, configured 0 usec | ||
385 | 342 | Flags: HARDWARE DECIBEL_VOLUME LATENCY | ||
386 | 343 | Properties: | ||
387 | 344 | alsa.resolution_bits = "16" | ||
388 | 345 | device.api = "alsa" | ||
389 | 346 | device.class = "sound" | ||
390 | 347 | alsa.class = "generic" | ||
391 | 348 | alsa.subclass = "generic-mix" | ||
392 | 349 | alsa.name = "" | ||
393 | 350 | alsa.id = "DMIC32 (*)" | ||
394 | 351 | alsa.subdevice = "0" | ||
395 | 352 | alsa.subdevice_name = "subdevice #0" | ||
396 | 353 | alsa.device = "6" | ||
397 | 354 | alsa.card = "0" | ||
398 | 355 | alsa.card_name = "sof-skl_hda_card" | ||
399 | 356 | alsa.long_card_name = "DellInc.-Inspiron5490--" | ||
400 | 357 | alsa.driver_name = "snd_soc_skl_hda_dsp" | ||
401 | 358 | device.bus_path = "pci-0000:00:1f.3-platform-skl_hda_dsp_generic" | ||
402 | 359 | sysfs.path = "/devices/pci0000:00/0000:00:1f.3/skl_hda_dsp_generic/sound/card0" | ||
403 | 360 | device.bus = "pci" | ||
404 | 361 | device.vendor.id = "8086" | ||
405 | 362 | device.vendor.name = "Intel Corporation" | ||
406 | 363 | device.product.id = "9dc8" | ||
407 | 364 | device.string = "hw:sofsklhdacard,6" | ||
408 | 365 | device.buffering.buffer_size = "65472" | ||
409 | 366 | device.buffering.fragment_size = "16320" | ||
410 | 367 | device.access_mode = "mmap+timer" | ||
411 | 368 | device.profile.name = "HiFi: hw:sofsklhdacard,6: source" | ||
412 | 369 | device.profile.description = "Digital Micrphone" | ||
413 | 370 | device.description = "sof-skl_hda_card Digital Micrphone" | ||
414 | 371 | module-udev-detect.discovered = "1" | ||
415 | 372 | device.icon_name = "audio-card-pci" | ||
416 | 373 | Ports: | ||
417 | 374 | [In] Dmic: Digital Micrphone (priority: 100) | ||
418 | 375 | Active Port: [In] Dmic | ||
419 | 376 | Formats: | ||
420 | 377 | pcm | ||
421 | 378 | |||
422 | 379 | Source #2 | ||
423 | 380 | State: SUSPENDED | ||
424 | 381 | Name: alsa_input.pci-0000_00_1f.3-platform-skl_hda_dsp_generic.HiFi__hw_sofsklhdacard_0__source | ||
425 | 382 | Description: sof-skl_hda_card Headset Mic | ||
426 | 383 | Driver: module-alsa-card.c | ||
427 | 384 | Sample Specification: s16le 2ch 48000Hz | ||
428 | 385 | Channel Map: front-left,front-right | ||
429 | 386 | Owner Module: 7 | ||
430 | 387 | Mute: no | ||
431 | 388 | Volume: front-left: 65536 / 100% / 0.00 dB, front-right: 65536 / 100% / 0.00 dB | ||
432 | 389 | balance 0.00 | ||
433 | 390 | Base Volume: 65536 / 100% / 0.00 dB | ||
434 | 391 | Monitor of Sink: n/a | ||
435 | 392 | Latency: 0 usec, configured 0 usec | ||
436 | 393 | Flags: HARDWARE DECIBEL_VOLUME LATENCY | ||
437 | 394 | Properties: | ||
438 | 395 | alsa.resolution_bits = "16" | ||
439 | 396 | device.api = "alsa" | ||
440 | 397 | device.class = "sound" | ||
441 | 398 | alsa.class = "generic" | ||
442 | 399 | alsa.subclass = "generic-mix" | ||
443 | 400 | alsa.name = "" | ||
444 | 401 | alsa.id = "HDA Analog (*)" | ||
445 | 402 | alsa.subdevice = "0" | ||
446 | 403 | alsa.subdevice_name = "subdevice #0" | ||
447 | 404 | alsa.device = "0" | ||
448 | 405 | alsa.card = "0" | ||
449 | 406 | alsa.card_name = "sof-skl_hda_card" | ||
450 | 407 | alsa.long_card_name = "DellInc.-Inspiron5490--" | ||
451 | 408 | alsa.driver_name = "snd_soc_skl_hda_dsp" | ||
452 | 409 | device.bus_path = "pci-0000:00:1f.3-platform-skl_hda_dsp_generic" | ||
453 | 410 | sysfs.path = "/devices/pci0000:00/0000:00:1f.3/skl_hda_dsp_generic/sound/card0" | ||
454 | 411 | device.bus = "pci" | ||
455 | 412 | device.vendor.id = "8086" | ||
456 | 413 | device.vendor.name = "Intel Corporation" | ||
457 | 414 | device.product.id = "9dc8" | ||
458 | 415 | device.string = "hw:sofsklhdacard,0" | ||
459 | 416 | device.buffering.buffer_size = "65472" | ||
460 | 417 | device.buffering.fragment_size = "16320" | ||
461 | 418 | device.access_mode = "mmap+timer" | ||
462 | 419 | device.profile.name = "HiFi: hw:sofsklhdacard,0: source" | ||
463 | 420 | device.profile.description = "Headset Mic" | ||
464 | 421 | device.description = "sof-skl_hda_card Headset Mic" | ||
465 | 422 | module-udev-detect.discovered = "1" | ||
466 | 423 | device.icon_name = "audio-card-pci" | ||
467 | 424 | Ports: | ||
468 | 425 | [In] Microphone: Headset Mic (priority: 100, available) | ||
469 | 426 | Active Port: [In] Microphone | ||
470 | 427 | Formats: | ||
471 | 428 | pcm | ||
472 | 429 | |||
473 | 430 | Client #0 | ||
474 | 431 | Driver: module-systemd-login.c | ||
475 | 432 | Owner Module: 18 | ||
476 | 433 | Properties: | ||
477 | 434 | application.name = "Login Session 1" | ||
478 | 435 | systemd-login.session = "1" | ||
479 | 436 | |||
480 | 437 | Client #1 | ||
481 | 438 | Driver: protocol-native.c | ||
482 | 439 | Owner Module: 11 | ||
483 | 440 | Properties: | ||
484 | 441 | application.name = "GNOME Shell" | ||
485 | 442 | native-protocol.peer = "UNIX socket client" | ||
486 | 443 | native-protocol.version = "32" | ||
487 | 444 | application.id = "org.gnome.Shell" | ||
488 | 445 | application.icon_name = "start-here" | ||
489 | 446 | application.language = "en_US.UTF-8" | ||
490 | 447 | window.x11.screen = "0" | ||
491 | 448 | window.x11.display = ":0" | ||
492 | 449 | application.process.id = "2238" | ||
493 | 450 | application.process.user = "test" | ||
494 | 451 | application.process.host = "test-Inspiron-5490" | ||
495 | 452 | application.process.binary = "gnome-shell" | ||
496 | 453 | application.process.machine_id = "61cc4f75157f4bb2bc4a9238c8f86c61" | ||
497 | 454 | application.process.session_id = "1" | ||
498 | 455 | |||
499 | 456 | Client #2 | ||
500 | 457 | Driver: protocol-native.c | ||
501 | 458 | Owner Module: 11 | ||
502 | 459 | Properties: | ||
503 | 460 | application.name = "GNOME Shell Volume Control" | ||
504 | 461 | native-protocol.peer = "UNIX socket client" | ||
505 | 462 | native-protocol.version = "32" | ||
506 | 463 | application.id = "org.gnome.VolumeControl" | ||
507 | 464 | application.icon_name = "multimedia-volume-control" | ||
508 | 465 | application.version = "3.28.1" | ||
509 | 466 | application.process.id = "2238" | ||
510 | 467 | application.process.user = "test" | ||
511 | 468 | application.process.host = "test-Inspiron-5490" | ||
512 | 469 | application.process.binary = "gnome-shell" | ||
513 | 470 | application.language = "en_US.UTF-8" | ||
514 | 471 | window.x11.display = ":0" | ||
515 | 472 | application.process.machine_id = "61cc4f75157f4bb2bc4a9238c8f86c61" | ||
516 | 473 | application.process.session_id = "1" | ||
517 | 474 | |||
518 | 475 | Client #8 | ||
519 | 476 | Driver: module-x11-xsmp.c | ||
520 | 477 | Owner Module: 26 | ||
521 | 478 | Properties: | ||
522 | 479 | application.name = "XSMP Session on gnome-session as 10a9331489bfab849a155721588398538200000021150058" | ||
523 | 480 | xsmp.vendor = "gnome-session" | ||
524 | 481 | xsmp.client.id = "10a9331489bfab849a155721588398538200000021150058" | ||
525 | 482 | |||
526 | 483 | Client #9 | ||
527 | 484 | Driver: protocol-native.c | ||
528 | 485 | Owner Module: 11 | ||
529 | 486 | Properties: | ||
530 | 487 | application.name = "GNOME Volume Control Media Keys" | ||
531 | 488 | native-protocol.peer = "UNIX socket client" | ||
532 | 489 | native-protocol.version = "32" | ||
533 | 490 | application.id = "org.gnome.VolumeControl" | ||
534 | 491 | application.icon_name = "multimedia-volume-control" | ||
535 | 492 | application.version = "" | ||
536 | 493 | application.process.id = "2461" | ||
537 | 494 | application.process.user = "test" | ||
538 | 495 | application.process.host = "test-Inspiron-5490" | ||
539 | 496 | application.process.binary = "gsd-media-keys" | ||
540 | 497 | application.language = "en_US.UTF-8" | ||
541 | 498 | window.x11.display = ":0" | ||
542 | 499 | application.process.machine_id = "61cc4f75157f4bb2bc4a9238c8f86c61" | ||
543 | 500 | application.process.session_id = "1" | ||
544 | 501 | |||
545 | 502 | Client #18 | ||
546 | 503 | Driver: module-systemd-login.c | ||
547 | 504 | Owner Module: 18 | ||
548 | 505 | Properties: | ||
549 | 506 | application.name = "Login Session 4" | ||
550 | 507 | systemd-login.session = "4" | ||
551 | 508 | |||
552 | 509 | Client #19 | ||
553 | 510 | Driver: module-systemd-login.c | ||
554 | 511 | Owner Module: 18 | ||
555 | 512 | Properties: | ||
556 | 513 | application.name = "Login Session 5" | ||
557 | 514 | systemd-login.session = "5" | ||
558 | 515 | |||
559 | 516 | Client #25 | ||
560 | 517 | Driver: protocol-native.c | ||
561 | 518 | Owner Module: 11 | ||
562 | 519 | Properties: | ||
563 | 520 | application.name = "pactl" | ||
564 | 521 | native-protocol.peer = "UNIX socket client" | ||
565 | 522 | native-protocol.version = "32" | ||
566 | 523 | application.process.id = "19283" | ||
567 | 524 | application.process.user = "test" | ||
568 | 525 | application.process.host = "test-Inspiron-5490" | ||
569 | 526 | application.process.binary = "pactl" | ||
570 | 527 | application.language = "en_US.UTF-8" | ||
571 | 528 | window.x11.display = "localhost:10.0" | ||
572 | 529 | application.process.machine_id = "61cc4f75157f4bb2bc4a9238c8f86c61" | ||
573 | 530 | application.process.session_id = "4" | ||
574 | 531 | |||
575 | 532 | Sample #0 | ||
576 | 533 | Name: bell.ogg | ||
577 | 534 | Sample Specification: float32le 1ch 44100Hz | ||
578 | 535 | Channel Map: mono | ||
579 | 536 | Volume: (invalid) | ||
580 | 537 | balance 0.00 | ||
581 | 538 | Duration: 0.2s | ||
582 | 539 | Size: 34.5 KiB | ||
583 | 540 | Lazy: no | ||
584 | 541 | Filename: n/a | ||
585 | 542 | Properties: | ||
586 | 543 | media.role = "event" | ||
587 | 544 | media.name = "bell.ogg" | ||
588 | 545 | application.name = "pactl" | ||
589 | 546 | native-protocol.peer = "UNIX socket client" | ||
590 | 547 | native-protocol.version = "32" | ||
591 | 548 | application.process.id = "2451" | ||
592 | 549 | application.process.user = "test" | ||
593 | 550 | application.process.host = "test-Inspiron-5490" | ||
594 | 551 | application.process.binary = "pactl" | ||
595 | 552 | application.language = "en_US.UTF-8" | ||
596 | 553 | window.x11.display = ":0" | ||
597 | 554 | application.process.machine_id = "61cc4f75157f4bb2bc4a9238c8f86c61" | ||
598 | 555 | application.process.session_id = "1" | ||
599 | 556 | |||
600 | 557 | Sample #1 | ||
601 | 558 | Name: bell-window-system | ||
602 | 559 | Sample Specification: s16le 1ch 44100Hz | ||
603 | 560 | Channel Map: mono | ||
604 | 561 | Volume: (invalid) | ||
605 | 562 | balance 0.00 | ||
606 | 563 | Duration: 0.2s | ||
607 | 564 | Size: 17.2 KiB | ||
608 | 565 | Lazy: no | ||
609 | 566 | Filename: n/a | ||
610 | 567 | Properties: | ||
611 | 568 | media.role = "event" | ||
612 | 569 | application.process.id = "3077" | ||
613 | 570 | application.name = "gnome-terminal-server" | ||
614 | 571 | event.description = "Bell event" | ||
615 | 572 | event.id = "bell-window-system" | ||
616 | 573 | media.name = "bell-window-system" | ||
617 | 574 | media.filename = "/usr/share/sounds/ubuntu/stereo/bell.ogg" | ||
618 | 575 | native-protocol.peer = "UNIX socket client" | ||
619 | 576 | native-protocol.version = "32" | ||
620 | 577 | application.id = "org.gnome.Shell" | ||
621 | 578 | application.icon_name = "start-here" | ||
622 | 579 | application.language = "en_US.UTF-8" | ||
623 | 580 | window.x11.screen = "0" | ||
624 | 581 | window.x11.display = ":0" | ||
625 | 582 | application.process.user = "test" | ||
626 | 583 | application.process.host = "test-Inspiron-5490" | ||
627 | 584 | application.process.binary = "gnome-shell" | ||
628 | 585 | application.process.machine_id = "61cc4f75157f4bb2bc4a9238c8f86c61" | ||
629 | 586 | application.process.session_id = "1" | ||
630 | 587 | |||
631 | 588 | Card #0 | ||
632 | 589 | Name: alsa_card.pci-0000_00_1f.3-platform-skl_hda_dsp_generic | ||
633 | 590 | Driver: module-alsa-card.c | ||
634 | 591 | Owner Module: 7 | ||
635 | 592 | Properties: | ||
636 | 593 | alsa.card = "0" | ||
637 | 594 | alsa.card_name = "sof-skl_hda_card" | ||
638 | 595 | alsa.long_card_name = "DellInc.-Inspiron5490--" | ||
639 | 596 | alsa.driver_name = "snd_soc_skl_hda_dsp" | ||
640 | 597 | device.bus_path = "pci-0000:00:1f.3-platform-skl_hda_dsp_generic" | ||
641 | 598 | sysfs.path = "/devices/pci0000:00/0000:00:1f.3/skl_hda_dsp_generic/sound/card0" | ||
642 | 599 | device.bus = "pci" | ||
643 | 600 | device.vendor.id = "8086" | ||
644 | 601 | device.vendor.name = "Intel Corporation" | ||
645 | 602 | device.product.id = "9dc8" | ||
646 | 603 | device.string = "0" | ||
647 | 604 | device.description = "sof-skl_hda_card" | ||
648 | 605 | module-udev-detect.discovered = "1" | ||
649 | 606 | device.icon_name = "audio-card-pci" | ||
650 | 607 | Profiles: | ||
651 | 608 | HiFi: Play HiFi quality Music (sinks: 1, sources: 2, priority: 8000, available: yes) | ||
652 | 609 | off: Off (sinks: 0, sources: 0, priority: 0, available: yes) | ||
653 | 610 | Active Profile: HiFi | ||
654 | 611 | Ports: | ||
655 | 612 | [Out] Speaker: Speaker (priority: 100, latency offset: 0 usec, not available) | ||
656 | 613 | Part of profile(s): HiFi | ||
657 | 614 | [Out] Headphone: Headphone (priority: 100, latency offset: 0 usec, available) | ||
658 | 615 | Part of profile(s): HiFi | ||
659 | 616 | [In] Dmic: Digital Micrphone (priority: 100, latency offset: 0 usec) | ||
660 | 617 | Part of profile(s): HiFi | ||
661 | 618 | [In] Microphone: Headset Mic (priority: 100, latency offset: 0 usec, available) | ||
662 | 619 | Part of profile(s): HiFi | ||
663 | diff --git a/checkbox_support/parsers/tests/test_pactl.py b/checkbox_support/parsers/tests/test_pactl.py | |||
664 | index a3d96dd..6f56d91 100644 | |||
665 | --- a/checkbox_support/parsers/tests/test_pactl.py | |||
666 | +++ b/checkbox_support/parsers/tests/test_pactl.py | |||
667 | @@ -631,6 +631,16 @@ class DocumentTests(ParsingTestCase, PactlDataMixIn): | |||
668 | 631 | )[0] | 631 | )[0] |
669 | 632 | self.assertEqual(len(document.record_list), 55) | 632 | self.assertEqual(len(document.record_list), 55) |
670 | 633 | 633 | ||
671 | 634 | def test_pactl_list_ports_with_pretag(self): | ||
672 | 635 | document = self.assertParses( | ||
673 | 636 | pactl.Document.Syntax, self.get_text("pa_ucm_pre_tag_bionic") | ||
674 | 637 | )[0] | ||
675 | 638 | self.assertEqual(len(document.record_list), 42) | ||
676 | 639 | self.assertEqual(document.record_list[27].name, "Sink #0") | ||
677 | 640 | self.assertEqual( | ||
678 | 641 | document.record_list[27].attribute_list[14].value[0].name, | ||
679 | 642 | "Speaker") | ||
680 | 643 | |||
681 | 634 | def test_pactl_list(self): | 644 | def test_pactl_list(self): |
682 | 635 | document = self.assertParses( | 645 | document = self.assertParses( |
683 | 636 | pactl.Document.Syntax, self.get_text("desktop-precise") | 646 | pactl.Document.Syntax, self.get_text("desktop-precise") |
Tested using:
$ LANG=C cat pactl_list.txt | python3 -m plainbox dev parse pactl-list