test: add a mock ModemManager for basic coverage of sd-networkd's integration

Just the minimal setup and test case required to cover
https://github.com/systemd/systemd/issues/41389 for now, can be
expanded in the future

Boring boilerplate is bot-made, don't @ me

Co-developed-by: Claude Opus 4.6 noreply@anthropic.com
This commit is contained in:
Luca Boccassi
2026-03-28 15:19:21 +00:00
parent e0ab84e21b
commit abe3d570f8
6 changed files with 595 additions and 0 deletions
@@ -0,0 +1,12 @@
# SPDX-License-Identifier: LGPL-2.1-or-later
[Match]
Name=dummy98
[Network]
LLDP=no
LinkLocalAddressing=no
IPv6AcceptRA=no
[MobileNetwork]
APN=internet.test
IPFamily=both
@@ -0,0 +1,13 @@
<!DOCTYPE busconfig PUBLIC
"-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
"http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
<busconfig>
<!-- Allow root to own and interact with the mock ModemManager service -->
<policy user="root">
<allow own="org.freedesktop.ModemManager1"/>
<allow send_destination="org.freedesktop.ModemManager1"/>
</policy>
<policy context="default">
<allow send_destination="org.freedesktop.ModemManager1"/>
</policy>
</busconfig>