本文整理汇总了Python中Crypto.SelfTest.st_common.list_test_cases方法的典型用法代码示例。如果您正苦于以下问题:Python st_common.list_test_cases方法的具体用法?Python st_common.list_test_cases怎么用?Python st_common.list_test_cases使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Crypto.SelfTest.st_common
的用法示例。
在下文中一共展示了st_common.list_test_cases方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
tests = []
tests += list_test_cases(RSATest)
try:
from Crypto.PublicKey import _fastmath
tests += list_test_cases(RSAFastMathTest)
except ImportError:
from distutils.sysconfig import get_config_var
import inspect
_fm_path = os.path.normpath(os.path.dirname(os.path.abspath(
inspect.getfile(inspect.currentframe())))
+"/../../PublicKey/_fastmath"+get_config_var("SO"))
if os.path.exists(_fm_path):
raise ImportError("While the _fastmath module exists, importing "+
"it failed. This may point to the gmp or mpir shared library "+
"not being in the path. _fastmath was found at "+_fm_path)
if config.get('slow_tests',1):
tests += list_test_cases(RSASlowMathTest)
return tests
示例2: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
tests = []
tests += list_test_cases(DSATest)
try:
from Crypto.PublicKey import _fastmath
tests += list_test_cases(DSAFastMathTest)
except ImportError:
from distutils.sysconfig import get_config_var
import inspect
_fm_path = os.path.normpath(os.path.dirname(os.path.abspath(
inspect.getfile(inspect.currentframe())))
+"/../../PublicKey/_fastmath"+get_config_var("SO"))
if os.path.exists(_fm_path):
raise ImportError("While the _fastmath module exists, importing "+
"it failed. This may point to the gmp or mpir shared library "+
"not being in the path. _fastmath was found at "+_fm_path)
tests += list_test_cases(DSASlowMathTest)
return tests
示例3: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
from Crypto.SelfTest.st_common import list_test_cases
return list_test_cases(FortunaAccumulatorTests)
示例4: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
from Crypto.SelfTest.st_common import list_test_cases
return list_test_cases(FortunaGeneratorTests)
示例5: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
tests = []
tests += list_test_cases(PKCS1_OAEP_Tests)
return tests
示例6: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
tests = []
tests += list_test_cases(PKCS1_15_Tests)
return tests
示例7: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
from Crypto.SelfTest.st_common import list_test_cases
listTests = []
listTests += list_test_cases(DerObjectTests)
listTests += list_test_cases(DerSequenceTests)
return listTests
示例8: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
from Crypto.SelfTest.st_common import list_test_cases
return list_test_cases(CounterTests)
示例9: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
from Crypto.SelfTest.st_common import list_test_cases
return list_test_cases(MiscTests)
示例10: get_tests
# 需要导入模块: from Crypto.SelfTest import st_common [as 别名]
# 或者: from Crypto.SelfTest.st_common import list_test_cases [as 别名]
def get_tests(config={}):
tests = []
tests += list_test_cases(PBKDF1_Tests)
tests += list_test_cases(PBKDF2_Tests)
return tests