mirror of
				https://github.com/python/cpython.git
				synced 2025-10-31 21:51:50 +00:00 
			
		
		
		
	 cf9d1a4b6b
			
		
	
	
		cf9d1a4b6b
		
			
		
	
	
	
	
		
			
			Adjust the tests for the `pathlib.types` module so that they can be run against the `pathlib-abc` PyPI package, which is a backport of the module for older Python versions. Specifically, we add a `.support.is_pypi` switch that is false in the stdlib and true in the pathlib-abc package. This controls which package we import, and whether or not we run tests against `PurePath` and `Path`. For compatibility with older Python versions, we stop using `zipfile.ZipFile.mkdir()` and `zipfile.ZipInfo._for_archive()`.
		
			
				
	
	
		
			2 lines
		
	
	
	
		
			91 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			2 lines
		
	
	
	
		
			91 B
		
	
	
	
		
			Python
		
	
	
	
	
	
| # Set to 'True' if the tests are run against the pathlib-abc PyPI package.
 | |
| is_pypi = False
 |