|
1 | 1 | # pylint: disable=missing-docstring, no-member, no-self-use, bad-super-call |
2 | 2 | # pylint: disable=too-few-public-methods, unused-argument, invalid-name, too-many-public-methods |
3 | 3 | # pylint: disable=line-too-long, useless-object-inheritance, arguments-out-of-order |
4 | | -# pylint: disable=super-with-arguments |
| 4 | +# pylint: disable=super-with-arguments, dangerous-default-value |
5 | 5 |
|
6 | 6 | def not_a_method(param, param2): |
7 | 7 | return super(None, None).not_a_method(param, param2) |
@@ -49,6 +49,9 @@ def with_default_argument_int(self, first, default_arg=42): |
49 | 49 | def with_default_argument_tuple(self, first, default_arg=()): |
50 | 50 | pass |
51 | 51 |
|
| 52 | + def with_default_argument_dict(self, first, default_arg={}): |
| 53 | + pass |
| 54 | + |
52 | 55 | def with_default_arg_ter(self, first, default_arg="has_been_changed"): |
53 | 56 | super().with_default_arg_ter(first, default_arg) |
54 | 57 |
|
@@ -160,6 +163,10 @@ def with_default_argument_tuple(self, first, default_arg=("42", "a")): |
160 | 163 | # Not useless because the default_arg is different from the one in the base class |
161 | 164 | super(NotUselessSuper, self).with_default_argument_tuple(first, default_arg) |
162 | 165 |
|
| 166 | + def with_default_argument_dict(self, first, default_arg={'foo': 'bar'}): |
| 167 | + # Not useless because the default_arg is different from the one in the base class |
| 168 | + super(NotUselessSuper, self).with_default_argument_dict(first, default_arg) |
| 169 | + |
163 | 170 | def with_default_argument_bis(self, first, default_arg="default"): |
164 | 171 | # Although the default_arg is the same as in the base class, the call signature |
165 | 172 | # differs. Thus it is not useless. |
@@ -226,6 +233,9 @@ def with_default_argument_int(self, first, default_arg=42): # [useless-super-del |
226 | 233 | def with_default_argument_tuple(self, first, default_arg=()): # [useless-super-delegation] |
227 | 234 | super(UselessSuper, self).with_default_argument_tuple(first, default_arg) |
228 | 235 |
|
| 236 | + def with_default_argument_dict(self, first, default_arg={}): # [useless-super-delegation] |
| 237 | + super(UselessSuper, self).with_default_argument_dict(first, default_arg) |
| 238 | + |
229 | 239 | def __init__(self): # [useless-super-delegation] |
230 | 240 | super(UselessSuper, self).__init__() |
231 | 241 |
|
|
0 commit comments