diff --git a/tests/test_treepoem.py b/tests/test_treepoem.py
index <HASH>..<HASH> 100644
--- a/tests/test_treepoem.py
+++ b/tests/test_treepoem.py
@@ -40,3 +40,5 @@ class TreepoemTestCase(unittest.TestCase):
                         barcode_type=barcode_type
                     ),
                 )
+
+            actual.close()
Close the in-memory image as well.