Joshua Hesketh | c94afc4 | 2014-09-06 13:30:09 +1000 | [diff] [blame] | 1 | # Copyright 2014 Rackspace Australia |
| 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the "License"); you may |
| 4 | # not use this file except in compliance with the License. You may obtain |
| 5 | # a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
| 11 | # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the |
| 12 | # License for the specific language governing permissions and limitations |
| 13 | # under the License. |
| 14 | |
| 15 | import logging |
| 16 | import testtools |
| 17 | |
| 18 | import zuul.trigger |
| 19 | |
| 20 | |
| 21 | class TestGerritTrigger(testtools.TestCase): |
| 22 | log = logging.getLogger("zuul.test_trigger") |
| 23 | |
| 24 | def test_trigger_abc(self): |
| 25 | # We only need to instantiate a class for this |
Joshua Hesketh | 352264b | 2015-08-11 23:42:08 +1000 | [diff] [blame^] | 26 | zuul.trigger.gerrit.GerritTrigger({}) |
Joshua Hesketh | c94afc4 | 2014-09-06 13:30:09 +1000 | [diff] [blame] | 27 | |
| 28 | def test_trigger_name(self): |
| 29 | self.assertEqual('gerrit', zuul.trigger.gerrit.GerritTrigger.name) |
| 30 | |
| 31 | |
| 32 | class TestTimerTrigger(testtools.TestCase): |
| 33 | log = logging.getLogger("zuul.test_trigger") |
| 34 | |
| 35 | def test_trigger_abc(self): |
| 36 | # We only need to instantiate a class for this |
Joshua Hesketh | 352264b | 2015-08-11 23:42:08 +1000 | [diff] [blame^] | 37 | zuul.trigger.timer.TimerTrigger({}) |
Joshua Hesketh | c94afc4 | 2014-09-06 13:30:09 +1000 | [diff] [blame] | 38 | |
| 39 | def test_trigger_name(self): |
| 40 | self.assertEqual('timer', zuul.trigger.timer.TimerTrigger.name) |
| 41 | |
| 42 | |
| 43 | class TestZuulTrigger(testtools.TestCase): |
| 44 | log = logging.getLogger("zuul.test_trigger") |
| 45 | |
| 46 | def test_trigger_abc(self): |
| 47 | # We only need to instantiate a class for this |
Joshua Hesketh | 352264b | 2015-08-11 23:42:08 +1000 | [diff] [blame^] | 48 | zuul.trigger.zuultrigger.ZuulTrigger({}) |
Joshua Hesketh | c94afc4 | 2014-09-06 13:30:09 +1000 | [diff] [blame] | 49 | |
| 50 | def test_trigger_name(self): |
| 51 | self.assertEqual('zuul', zuul.trigger.zuultrigger.ZuulTrigger.name) |