(self)
| 221 | self.assertEqual(check_run.output.annotations_count, 2) |
| 222 | |
| 223 | def testUpdateCheckRunSuccess(self): |
| 224 | # This is a different check run created for this test |
| 225 | check_run = self.testrepo.create_check_run( |
| 226 | name="edit_check_run", |
| 227 | head_sha="0283d46537193f1fed7d46859f15c5304b9836f9", |
| 228 | status="in_progress", |
| 229 | external_id="100", |
| 230 | started_at=datetime(2020, 10, 20, 14, 24, 31), |
| 231 | output={"title": "Check run for testing edit method", "summary": ""}, |
| 232 | ) |
| 233 | self.assertEqual(check_run.name, "edit_check_run") |
| 234 | self.assertEqual(check_run.status, "in_progress") |
| 235 | check_run.edit( |
| 236 | status="completed", |
| 237 | conclusion="success", |
| 238 | output={ |
| 239 | "title": "Check run for testing edit method", |
| 240 | "summary": "This is the summary of editing check run as completed.", |
| 241 | }, |
| 242 | ) |
| 243 | self.assertEqual(check_run.name, "edit_check_run") |
| 244 | self.assertEqual(check_run.status, "completed") |
| 245 | self.assertEqual(check_run.conclusion, "success") |
| 246 | self.assertEqual(check_run.output.title, "Check run for testing edit method") |
| 247 | self.assertEqual( |
| 248 | check_run.output.summary, |
| 249 | "This is the summary of editing check run as completed.", |
| 250 | ) |
| 251 | self.assertEqual(check_run.output.annotations_count, 0) |
| 252 | |
| 253 | def testUpdateCheckRunFailure(self): |
| 254 | # This is a different check run created for this test |
nothing calls this directly
no test coverage detected