forked from rc/aircox
- Writes tests for aircox streamer application; - Add test utilities in aircox Co-authored-by: bkfox <thomas bkfox net> Reviewed-on: rc/aircox#110
This commit is contained in:
15
aircox_streamer/tests/fake_modules/psutil.py
Normal file
15
aircox_streamer/tests/fake_modules/psutil.py
Normal file
@ -0,0 +1,15 @@
|
||||
"""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."""
|
Reference in New Issue
Block a user