Skip to content

Commit a32af48

Browse files
committed
chore: to merge
1 parent e04f309 commit a32af48

File tree

1 file changed

+6
-12
lines changed

1 file changed

+6
-12
lines changed

tests/test_colored_view.py

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -136,36 +136,30 @@ def test_colored_view_list_additions():
136136

137137
def test_colored_view_list_all_items_removed():
138138
"""Test that all removed items are displayed when list becomes empty."""
139-
t1 = [
140-
{"kind": "ServiceAccount", "name": "test-sa"},
141-
{"kind": "Deployment", "name": "test-deploy"}
142-
]
139+
t1 = [2, 4]
143140
t2 = []
144141

145142
diff = DeepDiff(t1, t2, view=COLORED_VIEW)
146143
result = str(diff)
147144

148145
expected = f'''[
149-
{RED}{{"kind": "ServiceAccount", "name": "test-sa"}}{RESET},
150-
{RED}{{"kind": "Deployment", "name": "test-deploy"}}{RESET}
146+
{RED}2{RESET},
147+
{RED}4{RESET}
151148
]'''
152149
assert result == expected
153150

154151

155152
def test_colored_compact_view_list_all_items_removed():
156153
"""Test that all removed items are displayed when list becomes empty with compact view."""
157-
t1 = [
158-
{"kind": "ServiceAccount", "name": "test-sa"},
159-
{"kind": "Deployment", "name": "test-deploy"}
160-
]
154+
t1 = [2, 4]
161155
t2 = []
162156

163157
diff = DeepDiff(t1, t2, view=COLORED_COMPACT_VIEW)
164158
result = str(diff)
165159

166160
expected = f'''[
167-
{RED}{{"kind": "ServiceAccount", "name": "test-sa"}}{RESET},
168-
{RED}{{"kind": "Deployment", "name": "test-deploy"}}{RESET}
161+
{RED}2{RESET},
162+
{RED}4{RESET}
169163
]'''
170164
assert result == expected
171165

0 commit comments

Comments
 (0)