File tree Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -14217,13 +14217,18 @@ def __get_test_id(self):
14217
14217
)
14218
14218
if self._sb_test_identifier and len(str(self._sb_test_identifier)) > 6:
14219
14219
test_id = self._sb_test_identifier
14220
- test_id = test_id.replace(".py::", ".").replace("::", ".")
14221
- test_id = test_id.replace("/", ".").replace(" ", "_")
14222
14220
elif hasattr(self, "_using_sb_fixture") and self._using_sb_fixture:
14223
14221
test_id = sb_config._latest_display_id
14224
- test_id = test_id.replace(".py::", ".").replace("::", ".")
14225
- test_id = test_id.replace("/", ".").replace(" ", "_")
14226
- return test_id
14222
+ test_id = test_id.replace(".py::", ".").replace("::", ".")
14223
+ test_id = test_id.replace("/", ".").replace(" ", "_")
14224
+ # Linux filename length limit for `codecs.open(filename)` = 255
14225
+ # 255 - len("latest_logs/") - len("/basic_test_info.txt") = 223
14226
+ if len(test_id) <= 223:
14227
+ return test_id
14228
+ else:
14229
+ # 223 - len("__TRUNCATED__") = 210
14230
+ # 210 / 2 = 105
14231
+ return test_id[:105] + "__TRUNCATED__" + test_id[-105:]
14227
14232
14228
14233
def __get_test_id_2(self):
14229
14234
"""The id for SeleniumBase Dashboard entries."""
You can’t perform that action at this time.
0 commit comments