diff options
author | Helmut Grohne <helmut@subdivi.de> | 2025-05-21 22:34:37 +0200 |
---|---|---|
committer | Helmut Grohne <helmut@subdivi.de> | 2025-05-21 22:34:37 +0200 |
commit | 58af839d8f7b47aea2c4ab37f2b5e168c03a3bb0 (patch) | |
tree | 93f272a456cdc4c039dd24c3a24a9ef8d827da60 /tests/test_simple.py | |
parent | 29ef6690e5ae0433821995c89ae682ad0fa7f80d (diff) | |
download | python-linuxnamespaces-58af839d8f7b47aea2c4ab37f2b5e168c03a3bb0.tar.gz |
agree a bit with black's formatting recommendations
Diffstat (limited to 'tests/test_simple.py')
-rw-r--r-- | tests/test_simple.py | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/tests/test_simple.py b/tests/test_simple.py index 07a0740..2b5252f 100644 --- a/tests/test_simple.py +++ b/tests/test_simple.py @@ -126,9 +126,13 @@ class AsnycioTest(unittest.IsolatedAsyncioTestCase): async def test_copyfd_file_sock(self) -> None: sock1, sock2 = socket.socketpair() - with sock1, sock2, linuxnamespaces.FileDescriptor( - os.open("/etc/passwd", os.O_RDONLY) - ) as rfd: + with ( + sock1, + sock2, + linuxnamespaces.FileDescriptor( + os.open("/etc/passwd", os.O_RDONLY) + ) as rfd, + ): fut = asyncio.ensure_future( linuxnamespaces.async_copyfd(rfd, sock1.fileno(), 999) ) @@ -139,9 +143,13 @@ class AsnycioTest(unittest.IsolatedAsyncioTestCase): async def test_copyfd_file_pipe(self) -> None: rfdp, wfdp = linuxnamespaces.FileDescriptor.pipe(blocking=False) - with rfdp, wfdp, linuxnamespaces.FileDescriptor( - os.open("/etc/passwd", os.O_RDONLY) - ) as rfd: + with ( + rfdp, + wfdp, + linuxnamespaces.FileDescriptor( + os.open("/etc/passwd", os.O_RDONLY) + ) as rfd, + ): fut = asyncio.ensure_future( linuxnamespaces.async_copyfd(rfd, wfdp, 999) ) |