| Total Complexity | 2 |
| Total Lines | 19 |
| Duplicated Lines | 0 % |
| 1 | import sys |
||
| 13 | @skipIf(which('gofmt') is None, 'gofmt is not installed') |
||
| 14 | class GoVetBearTest(LocalBearTestHelper): |
||
| 15 | |||
| 16 | def setUp(self): |
||
| 17 | self.section = Section("test section") |
||
| 18 | self.uut = GofmtBear(self.section, Queue()) |
||
| 19 | |||
| 20 | def test_run(self): |
||
| 21 | self.assertLinesInvalid(self.uut, |
||
| 22 | ['package main', |
||
| 23 | 'func main() {', |
||
| 24 | ' return 1', |
||
| 25 | '}']) |
||
| 26 | self.assertLinesValid(self.uut, |
||
| 27 | ['package main', |
||
| 28 | '', |
||
| 29 | 'func main() {', |
||
| 30 | '\treturn 1', |
||
| 31 | '}']) |
||
| 32 | |||
| 36 |