22Test module for the modules.peripheral module.
33"""
44import pytest
5- from machine import Pin , I2C
5+ from machine import Pin
66
77from pico_lte .modules .peripherals import Periph
88
@@ -33,8 +33,6 @@ def test_pin_set_up(self, periph):
3333 assert isinstance (periph .neopixel , Pin )
3434 assert periph .neopixel .pin_num == 15
3535 assert periph .neopixel .pin_dir == Pin .OUT
36- # Test the Qwiic protocol.
37- assert isinstance (periph .qwiic , I2C )
3836
3937 @pytest .mark .parametrize ("pin_value" , [0 , 1 ])
4038 def test_read_user_button (self , mocker , periph , pin_value ):
@@ -45,9 +43,3 @@ def test_read_user_button(self, mocker, periph, pin_value):
4543 def test_adjust_neopixel (self ):
4644 """No need since its a third-party library."""
4745 assert True
48-
49- @pytest .mark .parametrize ("mocked_response" , [[104 , 105 ], []])
50- def test_qwiic_scan (self , mocker , periph , mocked_response ):
51- """This method tests the qwiic_scan() with mocked responses."""
52- mocker .patch ("pico_lte.modules.peripherals.I2C.scan" , return_value = mocked_response )
53- assert periph .qwiic_scan () == mocked_response
0 commit comments