Update Unit Test

Co-authored-by: xtaodada <xtao@xtaolink.cn>
This commit is contained in:
洛水居室 2023-02-11 16:29:11 +08:00 committed by GitHub
parent a044de8582
commit 3839d00a95
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 2 additions and 6 deletions

View File

@ -62,7 +62,6 @@ class _Plugin:
return result
def _new_chat_members_handler_funcs(self) -> List[Tuple[int, Callable]]:
result = []
for attr in dir(self):
# noinspection PyUnboundLocalVariable

View File

@ -22,7 +22,6 @@ class HTTPXRequest(AbstractAsyncContextManager):
async def __aexit__(
self, exc_type: Optional[Type[BaseException]], exc_val: Optional[BaseException], exc_tb: Optional[TracebackType]
) -> None:
await self.initialize()
async def initialize(self):

View File

@ -112,13 +112,13 @@ class TestMaterial:
async def test_get_by_name():
material = await Material.get_by_name("地脉的新芽")
assert material.id == "i_73"
assert material.type == "角色培养素材"
assert material.type == "角色与武器培养素材"
assert "60级以上深渊法师掉落" in material.source
assert "勃发" in material.description
material = await Material.get_by_name("「黄金」的教导")
assert material.id == "i_431"
assert material.type == "天赋培养素材"
assert material.type == "角色天赋素材"
assert 2 in material.weekdays
assert "土的象" in material.description

View File

@ -114,7 +114,6 @@ class Traceback(BaseTraceback):
locals_max_depth: Optional[int]
def __init__(self, *args, locals_max_depth: Optional[int] = None, **kwargs):
kwargs.update({"show_locals": True})
super(Traceback, self).__init__(*args, **kwargs)
self.locals_max_depth = locals_max_depth
@ -291,7 +290,6 @@ class Traceback(BaseTraceback):
excluded = False
for frame_index, frame in enumerate(stack.frames):
if exclude_frames and frame_index in exclude_frames:
excluded = True
continue