Skip to content

Commit

Permalink
fix: printing modified dict correctly adds prefix on closing bracket …
Browse files Browse the repository at this point in the history
…as well
  • Loading branch information
netomi committed Nov 28, 2024
1 parent bec1ca1 commit f22e7b8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion otterdog/operations/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,8 +228,8 @@ def _print_modified_internal(
self.printer.println(f"{prefix}{key.ljust(max_key_length, ' ')} = {{")
self.printer.level_up()
self._print_modified_dict_internal(max_key_length, current_value, expected_value, prefix, color)
self.printer.println("}")
self.printer.level_down()
self.printer.println(f"{prefix}}}")
elif isinstance(expected_value, list):
self.printer.println(f"{prefix}{key.ljust(max_key_length, ' ')} = [")
self.printer.level_up()
Expand Down
2 changes: 1 addition & 1 deletion tests/operations/test_operation.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class OperationTest(unittest.TestCase):
' ~ 1 -> 3'
' - 2'
' ~ ]'
' }'
' ~ }'
'~ }',
),
]
Expand Down

0 comments on commit f22e7b8

Please sign in to comment.