Skip to content

Commit 545b47d

Browse files
committed
style: disable pylint too-few-public-methods
I think this lint is not useful, and makes writing small classes more difficult than it needs to be. Signed-off-by: Pablo Barbáchano <[email protected]>
1 parent 17846a3 commit 545b47d

File tree

6 files changed

+4
-9
lines changed

6 files changed

+4
-9
lines changed

tests/framework/http_api.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33

44
"""A simple HTTP client for the Firecracker API"""
55

6-
# pylint:disable=too-few-public-methods
7-
86
import urllib
97
from http import HTTPStatus
108

tests/framework/properties.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
# SPDX-License-Identifier: Apache-2.0
33

44
# pylint:disable=broad-except
5-
# pylint:disable=too-few-public-methods
65

76
"""
87
Metadata we want to attach to tests for further analysis and troubleshooting

tests/framework/state_machine.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
"""Defines a stream based string matcher and a generic state object."""
44

55

6-
# Too few public methods (1/2) (too-few-public-methods)
7-
# pylint: disable=R0903
86
class MatchStaticString:
97
"""Match a static string versus input."""
108

tests/framework/utils.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,6 @@ def __del__(self):
196196
self.proc.kill()
197197

198198

199-
# pylint: disable=too-few-public-methods
200199
class CpuMap:
201200
"""Cpu map from real cpu cores to containers visible cores.
202201

tests/integration_tests/functional/test_serial_io.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
PLATFORM = platform.machine()
1717

1818

19-
class WaitTerminal(TestState): # pylint: disable=too-few-public-methods
19+
class WaitTerminal(TestState):
2020
"""Initial state when we wait for the login prompt."""
2121

2222
def handle_input(self, serial, input_char) -> TestState:
@@ -27,7 +27,7 @@ def handle_input(self, serial, input_char) -> TestState:
2727
return self
2828

2929

30-
class WaitIDResult(TestState): # pylint: disable=too-few-public-methods
30+
class WaitIDResult(TestState):
3131
"""Wait for the console to show the result of the 'id' shell command."""
3232

3333
def handle_input(self, unused_serial, input_char) -> TestState:
@@ -37,7 +37,7 @@ def handle_input(self, unused_serial, input_char) -> TestState:
3737
return self
3838

3939

40-
class TestFinished(TestState): # pylint: disable=too-few-public-methods
40+
class TestFinished(TestState):
4141
"""Test complete and successful."""
4242

4343
def handle_input(self, unused_serial, _) -> TestState:

tests/pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,4 +54,5 @@ disable = [
5454
"broad-exception-raised",
5555
"duplicate-code",
5656
"too-many-positional-arguments",
57+
"too-few-public-methods",
5758
]

0 commit comments

Comments
 (0)