Beispiel #1
0
    def test_filters(self):
        from pylama.core import filter_errors

        self.assertTrue(
            filter_errors(dict(text='E'), select=['E'], ignore=['E101']))

        self.assertFalse(
            filter_errors(dict(text='W'), select=['W100'], ignore=['W']))
Beispiel #2
0
    def test_filters(self):
        from pylama.core import filter_errors

        self.assertTrue(filter_errors(
            dict(text='E'), select=['E'], ignore=['E101']
        ))

        self.assertFalse(filter_errors(
            dict(text='W'), select=['W100'], ignore=['W']
        ))
Beispiel #3
0
def test_filter_errors():
    assert list(filter_errors([Error(text='E')], select=['E'], ignore=['E101']))
    assert not list(filter_errors([Error(text='W')], select=['W100'], ignore=['W']))
Beispiel #4
0
def test_filter_errors():
    assert list(filter_errors([Error(text='E1')], select=['E'], ignore=['E101']))
    assert not list(filter_errors([Error(text='W1')], select=['W100'], ignore=['W']))