mirror of
https://github.com/pimoroni/grow-python
synced 2025-10-25 15:19:23 +00:00
Tweaks, fixes, linting and docs
This commit is contained in:
@@ -70,12 +70,3 @@ def atexit():
|
||||
sys.modules['atexit'] = atexit
|
||||
yield atexit
|
||||
del sys.modules['atexit']
|
||||
|
||||
|
||||
@pytest.fixture(scope='function', autouse=False)
|
||||
def numpy():
|
||||
"""Mock numpy module."""
|
||||
numpy = mock.MagicMock()
|
||||
sys.modules['numpy'] = numpy
|
||||
yield numpy
|
||||
del sys.modules['numpy']
|
||||
|
||||
@@ -9,7 +9,7 @@ def test_moisture_setup(GPIO, smbus):
|
||||
def test_moisture_read_all(GPIO, smbus):
|
||||
from grow import moisture
|
||||
moisture._is_setup = False
|
||||
|
||||
|
||||
result = moisture.read_all()
|
||||
|
||||
assert type(result(1)) == float
|
||||
|
||||
Reference in New Issue
Block a user