@@ -78,7 +78,7 @@ def test_concurrency_conflict(self) -> None:
78
78
target_copy = self ._get_concurrency_target ()
79
79
v1 = api .get_revision_of_object (target )
80
80
v2 = api .get_revision_of_object (target_copy )
81
- assert v1 == v2 , f"got same row with different version ({ v1 } /{ v2 } )"
81
+ assert v1 == v2 , f"got same row with different version ({ v1 } /{ v2 } )" # noqa: S101
82
82
target .save ()
83
83
assert target .pk is not None # sanity check
84
84
self .assertRaises (RecordModifiedError , target_copy .save )
@@ -88,15 +88,15 @@ def test_concurrency_safety(self) -> None:
88
88
89
89
target = self .concurrency_model ()
90
90
version = api .get_revision_of_object (target )
91
- assert not bool (version ), f"version is not null { version } "
91
+ assert not bool (version ), f"version is not null { version } " # noqa: S101
92
92
93
93
def test_concurrency_management (self ) -> None :
94
94
target = self .concurrency_model
95
- assert hasattr (target , "_concurrencymeta" ), f"{ self .concurrency_model } is not under concurrency management"
95
+ assert hasattr (target , "_concurrencymeta" ), f"{ self .concurrency_model } is not under concurrency management" # noqa: S101
96
96
97
97
revision_field = target ._concurrencymeta .field
98
98
99
- assert revision_field in target ._meta .fields , f"{ self .concurrency_model } : version field not in meta.fields"
99
+ assert revision_field in target ._meta .fields , f"{ self .concurrency_model } : version field not in meta.fields" # noqa: S101
100
100
101
101
102
102
class ConcurrencyAdminTestMixin :
@@ -153,15 +153,6 @@ def fqn(o):
153
153
"""
154
154
parts = []
155
155
156
- # if inspect.ismethod(o):
157
- # try:
158
- # cls = o.im_class
159
- # except AttributeError:
160
- # # Python 3 eliminates im_class, substitutes __module__ and
161
- # # __qualname__ to provide similar information.
162
- # parts = (o.__module__, o.__qualname__)
163
- # else:
164
- # parts = (fqn(cls), get_classname(o))
165
156
if hasattr (o , "__module__" ):
166
157
parts .extend ((o .__module__ , get_classname (o )))
167
158
elif inspect .ismodule (o ):
0 commit comments