Skip to content
Snippets Groups Projects
Commit e7f9fef7 authored by Stewart Perrygrove's avatar Stewart Perrygrove
Browse files

Adds a test for get_attachments

parent 0360f804
No related branches found
No related tags found
No related merge requests found
......@@ -139,6 +139,10 @@ class RtTestCase(unittest.TestCase):
self.assertGreater(at_ids, 0, 'Emply list with attachment ids, something went wrong.')
at_content = tracker.get_attachment_content(ticket_id, at_ids[-1])
self.assertEqual(at_content, attachment_content, 'Recorded attachment is not equal to the original file.')
# attachments list
at_list = tracker.get_attachments(ticket_id)
at_names = [at[1] for at in at_list]
self.assertIn(attachment_name, at_names)
if __name__ == '__main__':
unittest.main()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment