mirror of
https://github.com/henrydcase/pqc.git
synced 2024-11-27 09:51:30 +00:00
0bc19b3633
* Minor changes * Gracefully degrade if clang-tidy segfaults * Typo on returncode
31 lines
634 B
Python
31 lines
634 B
Python
"""
|
|
Runs functional tests for common crypto functions (e.g., fips202, sha2, aes).
|
|
"""
|
|
|
|
import os
|
|
import re
|
|
|
|
import helpers
|
|
|
|
|
|
@helpers.skip_windows()
|
|
def test_common():
|
|
for d in os.listdir('common'):
|
|
primitive = re.sub(r"\.c$", "", d)
|
|
if helpers.permit_test('common', None): yield check_common, primitive
|
|
|
|
|
|
def check_common(primitive):
|
|
binname = os.path.join('..', 'bin', 'test_common_'+primitive)
|
|
helpers.make(binname)
|
|
helpers.run_subprocess([binname])
|
|
|
|
|
|
if __name__ == '__main__':
|
|
try:
|
|
import nose2
|
|
nose2.main()
|
|
except ImportError:
|
|
import nose
|
|
nose.runmodule()
|