Rally python api - Adding a Tag to an entity?

533 views Asked by At

I wanted to use pyral to add tags to defects and I couldn't figure out how to do it

info = dict(test_id="ABC", platform="AAA")
tag1 = rally.create('Tag', dict(Name=info['test_id']))
tag2 = rally.create('Tag', dict(Name=info['platform']))

what's next ?

1

There are 1 answers

3
Fruch On BEST ANSWER

found an answer here: how to tag a defect using rally Javascript API

anyhow adding it to documentation might help:

tag1 = rally.create('Tag', dict(Name=info['test_id']))
tag2 = rally.create('Tag', dict(Name=info['platform']))

tags = [ dict(_ref=tag1.ref), dict(_ref=tag2.ref)]

defect = { "Tags" : tags }