mirror of
				https://github.com/KevinMidboe/python-gpiozero.git
				synced 2025-10-29 17:50:37 +00:00 
			
		
		
		
	Change MockPin (and MockPWMPin) to make them behave more like 'real' pins - fixes #206 Add new MockPin tests, and rework some of the existing ones Incorporate #216
		
			
				
	
	
		
			20 lines
		
	
	
		
			291 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			20 lines
		
	
	
		
			291 B
		
	
	
	
		
			Python
		
	
	
	
	
	
| from __future__ import (
 | |
|     unicode_literals,
 | |
|     absolute_import,
 | |
|     print_function,
 | |
|     division,
 | |
|     )
 | |
| str = type('')
 | |
| 
 | |
| 
 | |
| import pytest
 | |
| 
 | |
| from gpiozero.pins.mock import MockPin
 | |
| from gpiozero import *
 | |
| 
 | |
| 
 | |
| def teardown_function(function):
 | |
|     MockPin.clear_pins()
 | |
| 
 | |
| # TODO input_devices tests!
 |