Use a ResourceManager to find assets
This commit is contained in:
@ -2,6 +2,7 @@ import unittest
|
||||
|
||||
from squirrelbattle.display.texturepack import TexturePack
|
||||
from squirrelbattle.interfaces import Map, Tile
|
||||
from squirrelbattle.resources import ResourceManager
|
||||
|
||||
|
||||
class TestInterfaces(unittest.TestCase):
|
||||
@ -18,7 +19,7 @@ class TestInterfaces(unittest.TestCase):
|
||||
"""
|
||||
Try to load a map from a file.
|
||||
"""
|
||||
m = Map.load("squirrelbattle/assets/example_map.txt")
|
||||
m = Map.load(ResourceManager.get_asset_path("example_map.txt"))
|
||||
self.assertEqual(m.width, 52)
|
||||
self.assertEqual(m.height, 17)
|
||||
|
||||
|
Reference in New Issue
Block a user