test: do not fail network namespace test with permission issues
authorLuca Boccassi <bluca@debian.org>
Tue, 21 May 2024 00:43:24 +0000 (01:43 +0100)
committerLuca Boccassi <bluca@debian.org>
Wed, 22 May 2024 15:51:38 +0000 (16:51 +0100)
commit6ab21f20bd982bc1a9ece47dcffa1137a76cc48a
tree65f38191a7cbbe09dc8d8353211a10764982b27c
parent06384eb3c5044f632f50304a0210a402460f1189
test: do not fail network namespace test with permission issues

When running in LXC with AppArmor we'll most likely get an error when creating
a network namespace due to a kernel regression in < v6.2 affecting AppArmor,
resulting in denials. Like other tests, avoid failing in case of permission
issues and handle it gracefully.
src/test/test-namespace.c