Beispiel #1
0
 def test_include_stage_for_failing_builds(self):
     params = self.factory(status='failed')
     body = message_builder(**params)
     self.assertIn('Stage:', body['text'])
Beispiel #2
0
 def test_include_stage_for_broken_builds(self):
     params = self.factory(status='is broken')
     body = message_builder(**params)
     self.assertIn('Stage:', body['text'])
Beispiel #3
0
 def test_exclude_changeset_for_deploy_stages(self):
     for stage in TEST_DEPLOY_STAGES:
         params = self.factory(stage=stage, status='passed')
         body = message_builder(**params)
         self.assertNotIn('Changeset:', body['text'])
Beispiel #4
0
 def test_include_changeset_for_ci_stages(self):
     for stage in TEST_CI_STAGES:
         params = self.factory(stage=stage, status='passed')
         body = message_builder(**params)
         self.assertIn('Changeset:', body['text'])
Beispiel #5
0
 def test_x_icon_for_broken_build(self):
     params = self.factory(stage='package', status='is broken')
     body = message_builder(**params)
     self.assertEqual(':x:', body['icon_emoji'])
Beispiel #6
0
 def test_tick_icon_for_fixed_build(self):
     params = self.factory(stage='package', status='is fixed')
     body = message_builder(**params)
     self.assertEqual(':white_check_mark:', body['icon_emoji'])
Beispiel #7
0
 def test_exclude_stage_for_passing_builds(self):
     params = self.factory(status='passed')
     body = message_builder(**params)
     self.assertNotIn('Stage:', body['text'])