Skip to content

Commit a232364

Browse files
add test for previos commmit
d2ffefa
1 parent d2ffefa commit a232364

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

tests/test_vdf.py

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -477,6 +477,33 @@ def test_inline_opening_bracker(self):
477477
self.assertEqual(vdf.loads(INPUT), EXPECTED)
478478
self.assertEqual(vdf.loads(INPUT, escaped=False), EXPECTED)
479479

480+
def test_duplicate_key_with_value_from_str_to_mapper(self):
481+
INPUT = r'''
482+
level1
483+
{
484+
key1 text1
485+
key2 text2
486+
}
487+
level1
488+
{
489+
key2
490+
{
491+
key3 text3
492+
}
493+
}
494+
'''
495+
496+
EXPECTED = {
497+
"level1": {
498+
"key1": "text1",
499+
"key2": {
500+
"key3": "text3"
501+
}
502+
}
503+
}
504+
505+
self.assertEqual(vdf.loads(INPUT), EXPECTED)
506+
480507
class testcase_VDF_other(unittest.TestCase):
481508
def test_dumps_pretty_output(self):
482509
tests = [

0 commit comments

Comments
 (0)