aircox-radiocampus/aircox_streamer/tests/fake_modules/psutil.py
Thomas Kairos b453c821c7 #106: tests: aircox_streamer (#110)
- Writes tests for aircox streamer application;
- Add test utilities in aircox

Co-authored-by: bkfox <thomas bkfox net>
Reviewed-on: rc/aircox#110
2023-06-18 17:00:08 +02:00

16 lines
325 B
Python

"""Spoof psutil module in order to run and check tests."""
class FakeNetConnection:
def __init__(self, laddr, pid=None):
self.laddr = laddr
self.pid = pid
def net_connections(*args, **kwargs):
return net_connections.result
net_connections.result = []
"""Result value of net_connections call."""