()
| 3 | |
| 4 | |
| 5 | def test_session(): |
| 6 | if not util.credentials_available(): |
| 7 | warnings.warn("Skipped test_session because there were no credentials available.") |
| 8 | return |
| 9 | sess = util.session() |
| 10 | shared, unshared, studios = sess.mystuff_counts() |
| 11 | assert shared >= 3 |
| 12 | assert unshared >= 2 |
| 13 | assert studios >= 1 |
| 14 | |
| 15 | sess = util.teacher_session() |
| 16 | if not sess: |
| 17 | warnings.warn("Skipped test_session (teacher) because there was no teacher account available") |
| 18 | return |
| 19 | |
| 20 | open_count, closed_count = sess.mystuff_classes_counts() |
| 21 | assert open_count >= 2 |
| 22 | assert closed_count >= 1 |
| 23 | |
| 24 | |
| 25 | if __name__ == "__main__": |
no test coverage detected