mirror of
				https://github.com/python/cpython.git
				synced 2025-11-03 23:21:29 +00:00 
			
		
		
		
	Very simple test for ctypes.util.find_library on Windows.
This commit is contained in:
		
							parent
							
								
									95ba13fa85
								
							
						
					
					
						commit
						ee130b72f8
					
				
					 1 changed files with 2 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -6,7 +6,7 @@
 | 
			
		|||
 | 
			
		||||
libc_name = None
 | 
			
		||||
if os.name == "nt":
 | 
			
		||||
    libc_name = "msvcrt"
 | 
			
		||||
    libc_name = find_library("c")
 | 
			
		||||
elif os.name == "ce":
 | 
			
		||||
    libc_name = "coredll"
 | 
			
		||||
elif sys.platform == "cygwin":
 | 
			
		||||
| 
						 | 
				
			
			@ -43,6 +43,7 @@ def test_find(self):
 | 
			
		|||
 | 
			
		||||
    if os.name in ("nt", "ce"):
 | 
			
		||||
        def test_load_library(self):
 | 
			
		||||
            self.failIf(libc_name is None)
 | 
			
		||||
            if is_resource_enabled("printing"):
 | 
			
		||||
                print find_library("kernel32")
 | 
			
		||||
                print find_library("user32")
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue