()
| 6 | |
| 7 | |
| 8 | def test_activity(): |
| 9 | if not util.credentials_available(): |
| 10 | warnings.warn( |
| 11 | "Skipped test_activity because there were no credentials available." |
| 12 | ) |
| 13 | return |
| 14 | sess = util.session() |
| 15 | |
| 16 | # we cannot do assertions, but we can probe for any errors. |
| 17 | messages = sess.messages() |
| 18 | for msg in messages: |
| 19 | print(msg, end=" ") |
| 20 | |
| 21 | try: |
| 22 | target = msg.target() |
| 23 | except exceptions.CommentNotFound: |
| 24 | target = None |
| 25 | raise |
| 26 | |
| 27 | print(target) |
| 28 | |
| 29 | |
| 30 | if __name__ == "__main__": |
no test coverage detected