texture: Clear the existing texture cache before testing

This test started failing after updating to pytest 8.0. I fix it by
clearing the cache so the test can begin with a clear slate.

Signed-off-by: Anna Schumaker <Anna@NoWheyCreamery.com>
This commit is contained in:
Anna Schumaker 2024-01-29 14:36:10 -05:00
parent 6c6ebf3676
commit 3c15515faf
1 changed files with 4 additions and 0 deletions

View File

@ -12,6 +12,10 @@ from gi.repository import Gdk
class TestTextureCache(unittest.TestCase):
"""Test our custom cache dictionary."""
def setUpClass():
"""Clear the existing cache before testing."""
emmental.texture.CACHE.clear()
def setUp(self):
"""Set up common variables."""
cover = tests.util.COVER_JPG.absolute().relative_to("/")