def test_should_filter_the_warnings(self): option = Mock(thresholds={'cyclomatic_complexity':15, 'length':1000}) warnings = list(warning_filter(option, [self.fileStat])) self.assertEqual(1, len(warnings)) self.assertEqual("complex", warnings[0].name)
def test_should_filter_the_warnings(self): option = Mock(CCN=15, arguments=10) warnings = list(warning_filter(option, [self.fileStat])) self.assertEqual(1, len(warnings)) self.assertEqual("complex", warnings[0][0].name)
def test_should_filter_the_warnings(self): option = Mock(thresholds={'cyclomatic_complexity': 15, 'length': 1000}) warnings = list(warning_filter(option, [self.fileStat])) self.assertEqual(1, len(warnings)) self.assertEqual("complex", warnings[0].name)