You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

29 lines
578 B

  1. """
  2. Checks that no implementation makes use of symbolic links.
  3. """
  4. import os
  5. import pytest
  6. import helpers
  7. import pqclean
  8. @pytest.mark.parametrize(
  9. 'implementation',
  10. pqclean.Scheme.all_implementations(),
  11. ids=str,
  12. )
  13. @helpers.filtered_test
  14. def test_no_symlinks(implementation):
  15. for file in os.listdir(implementation.path()):
  16. fpath = os.path.join(implementation.path(), file)
  17. if os.path.islink(fpath):
  18. raise AssertionError("{} is a symbolic link!".format(fpath))
  19. if __name__ == '__main__':
  20. import sys
  21. pytest.main(sys.argv)