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
602 B

  1. import pytest
  2. import helpers
  3. import pqclean
  4. @pytest.mark.parametrize(
  5. 'implementation',
  6. pqclean.Scheme.all_implementations(),
  7. ids=str,
  8. )
  9. @helpers.filtered_test
  10. def test_format(implementation: pqclean.Implementation):
  11. helpers.ensure_available('astyle')
  12. cfiles = implementation.cfiles()
  13. hfiles = implementation.hfiles()
  14. result = helpers.run_subprocess(
  15. ['astyle',
  16. '--dry-run',
  17. '--options=../.astylerc',
  18. *cfiles,
  19. *hfiles])
  20. assert 'Formatted' not in result
  21. if __name__ == '__main__':
  22. import sys
  23. pytest.main(sys.argv)