audio playback fixes
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* The `q` (quit) action routes through `process.exit(0)`, which bypasses
|
||||
* Solid's onCleanup (where useAudio's onCleanup disposes the backend). To
|
||||
* keep spawned players (mpv/ffplay/afplay) from surviving the host, useAudio
|
||||
* keep spawned players (mpv) from surviving the host, useAudio
|
||||
* registers a `process.on("exit")` handler that synchronously disposes the
|
||||
* backend. The exit handler's whole job is "kill the child process", so this
|
||||
* test pins the contract directly: a backend holding a real spawned subprocess
|
||||
@@ -11,7 +11,7 @@
|
||||
*
|
||||
* Uses a real `Bun.spawn(["sleep", "60"])` subprocess as a stand-in for the
|
||||
* player process, injected into the (private) `proc` slot of an MpvBackend —
|
||||
* mpv/ffplay/afplay all share the identical kill-on-dispose pattern, so
|
||||
* mpv is the only real backend, and it uses the kill-on-dispose
|
||||
* exercising one is enough to guard the family.
|
||||
*/
|
||||
import { test, expect } from "bun:test";
|
||||
|
||||
Reference in New Issue
Block a user