mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Change methods not using its bound instance to staticmethods
This commit is contained in:
parent
deab57c6dc
commit
25701aac4f
11 changed files with 40 additions and 20 deletions
|
|
@ -30,22 +30,26 @@ class Test_check_token:
|
|||
This case gonna be deleted
|
||||
"""
|
||||
|
||||
def test_ok(self, data):
|
||||
@staticmethod
|
||||
def test_ok(data):
|
||||
if check_token(data, TOKEN) is not True:
|
||||
raise AssertionError
|
||||
|
||||
def test_fail(self, data):
|
||||
@staticmethod
|
||||
def test_fail(data):
|
||||
data.pop("username")
|
||||
if check_token(data, TOKEN) is not False:
|
||||
raise AssertionError
|
||||
|
||||
|
||||
class Test_check_integrity:
|
||||
def test_ok(self, data):
|
||||
@staticmethod
|
||||
def test_ok(data):
|
||||
if check_integrity(TOKEN, data) is not True:
|
||||
raise AssertionError
|
||||
|
||||
def test_fail(self, data):
|
||||
@staticmethod
|
||||
def test_fail(data):
|
||||
data.pop("username")
|
||||
if check_integrity(TOKEN, data) is not False:
|
||||
raise AssertionError
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue