mirror of
				https://github.com/python-pillow/Pillow.git
				synced 2025-11-04 09:57:43 +03:00 
			
		
		
		
	Fix ResourceWarning: unclosed file
This commit is contained in:
		
							parent
							
								
									fb0aad5abd
								
							
						
					
					
						commit
						2b9e230f76
					
				| 
						 | 
					@ -16,10 +16,10 @@ def test_sanity():
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
def test_reload():
 | 
					def test_reload():
 | 
				
			||||||
    im = Image.open("Tests/images/hopper.gif")
 | 
					    with Image.open("Tests/images/hopper.gif") as im:
 | 
				
			||||||
    original = im.copy()
 | 
					        original = im.copy()
 | 
				
			||||||
    im.palette.dirty = 1
 | 
					        im.palette.dirty = 1
 | 
				
			||||||
    assert_image_equal(im.convert("RGB"), original.convert("RGB"))
 | 
					        assert_image_equal(im.convert("RGB"), original.convert("RGB"))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
def test_getcolor():
 | 
					def test_getcolor():
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue
	
	Block a user