Skip to content

Commit 2e82bcd

Browse files
Merge pull request #798 from adamtheturtle/better-test-add
Expand test for add target
2 parents f7fd904 + fbaf63c commit 2e82bcd

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

tests/test_add_target.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,18 @@ def test_add_target(
2222
"""
2323
No exception is raised when adding one target.
2424
"""
25-
client.add_target(name='x', width=1, image=high_quality_image)
25+
name = 'x'
26+
width = 1
27+
target_id = client.add_target(
28+
name=name,
29+
width=width,
30+
image=high_quality_image,
31+
)
32+
get_result = client.get_target(target_id=target_id)
33+
target_record = get_result['target_record']
34+
assert target_record['name'] == name
35+
assert target_record['width'] == width
36+
assert target_record['active_flag'] is True
2637

2738
def test_add_two_targets(
2839
self,

0 commit comments

Comments
 (0)