mirror of
https://github.com/Threnklyn/dungeon-sheets.git
synced 2026-05-24 06:38:28 +02:00
Foundry JSON file now resolves magic item names.
This commit is contained in:
+12
-1
@@ -226,7 +226,7 @@ class FoundryReaderTests(unittest.TestCase):
|
||||
gp=162,
|
||||
pp=2,
|
||||
weapons=["rapier"],
|
||||
magic_items=(),
|
||||
# magic_items=(),
|
||||
armor="padded armor",
|
||||
shield="shield",
|
||||
personality_traits="Loves a good lawyer joke.",
|
||||
@@ -284,3 +284,14 @@ class FoundryReaderTests(unittest.TestCase):
|
||||
this_result = list(this_result)
|
||||
self.assertEqual(this_result, val, key)
|
||||
|
||||
def test_load_homebrew_weapon(self):
|
||||
"""Check that the properties of a homebrew magic weapon get read
|
||||
properly.
|
||||
|
||||
"""
|
||||
charfile = FOUNDRY_JSON_FILE
|
||||
with warnings.catch_warnings(record=True):
|
||||
result = read_sheet_file(charfile)
|
||||
# Check that some magic items were set
|
||||
self.assertGreater(len(result['magic_items']), 0,
|
||||
"No magic items imported")
|
||||
|
||||
Reference in New Issue
Block a user