Commit graph

1 commit

Author SHA1 Message Date
Vadim Peretokin
827b32e875
Infrastructure: add Discord IPC server stub for end-to-end tests (#9475)
#### Brief overview of PR changes/additions

Adds `DiscordIpcServerStub`, a `QLocalServer` that speaks the
discord-rpc wire protocol: it performs the handshake, replies with a
`DISPATCH`/`READY` carrying a configurable username, and records
`SET_ACTIVITY` frames for assertions (with Windows named-pipe support).
This lets tests reach genuine Discord states headlessly with no Discord
client running. Two new end-to-end cases exercise real-IPC read-only
gating and `SET_ACTIVITY` payload capture.

#### Motivation for adding to Mudlet

Groundwork for later Discord Lua-API spec coverage: tests can now drive
the real discord-rpc handshake end-to-end without a live Discord client.

#### Other info (issues closed, discussion etc)

Stacked on #9472 (`fix-discord-permission-gating`); merge after that
base gating PR.

Tested by hand. Squash-merge with:
```
Assisted-by: Claude:claude-fable-5
Signed-off-by: Vadim Peretokin <vadim.peretokin@mudlet.org>
```
2026-07-27 20:40:16 +02:00