mirror of
				https://github.com/python-pillow/Pillow.git
				synced 2025-10-31 07:57:27 +03:00 
			
		
		
		
	Simplify skipping
This commit is contained in:
		
							parent
							
								
									e33812c56c
								
							
						
					
					
						commit
						06ad343d35
					
				|  | @ -5,19 +5,12 @@ from PIL import __version__ | |||
| try: | ||||
|     import pyroma | ||||
| except ImportError: | ||||
|     # Skip via setUp() | ||||
|     pass | ||||
|     pyroma = None | ||||
| 
 | ||||
| 
 | ||||
| class TestPyroma(PillowTestCase): | ||||
| 
 | ||||
|     def setUp(self): | ||||
|         try: | ||||
|             import pyroma | ||||
|             assert pyroma  # Ignore warning | ||||
|         except ImportError: | ||||
|             self.skipTest("ImportError") | ||||
| 
 | ||||
|     @unittest.skipUnless(pyroma, "Pyroma is not installed") | ||||
|     def test_pyroma(self): | ||||
|         # Arrange | ||||
|         data = pyroma.projectdata.get_data(".") | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user