def test_find_all(self, display): touchpads = Touchpad.find_all(display) assert touchpads assert all(isinstance(t, Touchpad) for t in touchpads) assert all('Synaptics Off' in t for t in touchpads)
def test_no_touchpad(display): assert not list(Touchpad.find_all(display)) with pytest.raises(NoTouchpadError): Touchpad.find_first(display)