コード例 #1
0
 def test_b006(self):
     filename = Path(__file__).absolute().parent / 'b006.py'
     bbc = BugBearChecker(filename=str(filename))
     errors = list(bbc.run())
     self.assertEqual(
         errors,
         self.errors(B006(8, 24), B006(12, 29), B006(16, 19), B006(20, 19)),
     )
コード例 #2
0
 def test_b006_b008(self):
     filename = Path(__file__).absolute().parent / 'b006_b008.py'
     bbc = BugBearChecker(filename=str(filename))
     errors = list(bbc.run())
     self.assertEqual(
         errors,
         self.errors(B006(10, 24), B006(14, 29), B006(18, 19), B006(22, 19),
                     B006(25, 31), B008(32, 38)),
     )
コード例 #3
0
 def test_b006_b008(self):
     filename = Path(__file__).absolute().parent / "b006_b008.py"
     bbc = BugBearChecker(filename=str(filename))
     errors = list(bbc.run())
     self.assertEqual(
         errors,
         self.errors(
             B006(14, 24),
             B006(18, 29),
             B006(22, 19),
             B006(26, 19),
             B006(30, 31),
             B008(39, 38),
             B006(53, 32),
         ),
     )
コード例 #4
0
 def test_b006_b008(self):
     filename = Path(__file__).absolute().parent / "b006_b008.py"
     bbc = BugBearChecker(filename=str(filename))
     errors = list(bbc.run())
     self.assertEqual(
         errors,
         self.errors(
             B006(26, 24),
             B006(30, 29),
             B006(34, 19),
             B006(38, 19),
             B006(42, 31),
             B008(51, 38),
             B006(67, 32),
             B008(95, 29),
             B008(99, 44),
         ),
     )
コード例 #5
0
 def test_b006_b008(self):
     filename = Path(__file__).absolute().parent / "b006_b008.py"
     bbc = BugBearChecker(filename=str(filename))
     errors = list(bbc.run())
     self.assertEqual(
         errors,
         self.errors(
             B006(29, 24),
             B006(33, 29),
             B006(37, 19),
             B006(41, 19),
             B006(45, 31),
             B008(54, 38),
             B006(70, 32),
             B008(98, 29),
             B008(102, 44),
         ),
     )