From 96d75d9f1fab87365d7e6b5070eed3a5757c3484 Mon Sep 17 00:00:00 2001 From: James O'Doherty Date: Fri, 22 May 2026 09:18:55 -0400 Subject: Refactor CLI for testability and implement hermetic config path injection --- internal/namespace/namespace_test.go | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'internal/namespace') diff --git a/internal/namespace/namespace_test.go b/internal/namespace/namespace_test.go index cfa0e9b..e39710d 100644 --- a/internal/namespace/namespace_test.go +++ b/internal/namespace/namespace_test.go @@ -7,18 +7,16 @@ import ( ) func TestNamespaceCreation(t *testing.T) { - t.Log("Integration Test: Verifying CLONE_NEWUSER and CLONE_NEWNET syscalls") - // TODO: Verify that unshare creates a new network namespace - // TODO: Verify that the process has root privileges inside the namespace + // Test that CLONE_NEWUSER and CLONE_NEWNET are called in the correct sequence and a netns is created. + t.Skip("not implemented") } func TestNamespacePinning(t *testing.T) { - t.Log("Integration Test: Verifying bind-mount of namespace to /run/user/$UID/wg-wrap/") - // TODO: Verify that the namespace survives after the process exits - // TODO: Verify that we can re-join the namespace via setns + // Test that the network namespace is bind-mounted to /run/user/$UID/wg-wrap/ and persists after process exit. + t.Skip("not implemented") } func TestRoutingSetup(t *testing.T) { - t.Log("Integration Test: Verifying TUN device creation and IP routing table setup") - // TODO: Mock 'ip' command or use netlink to verify route exists + // Test that the TUN device is created and the routing table is configured with the correct VPN subnet. + t.Skip("not implemented") } -- cgit v1.2.3