meson.build 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. common_functions = configure_file(input: 'tests-common-functions.in',
  2. output: 'tests-common-functions',
  3. configuration: luksmeta_data,
  4. install: false
  5. )
  6. env = environment()
  7. env.prepend('PATH',
  8. join_paths(meson.source_root(), 'src'),
  9. join_paths(meson.source_root(), 'src', 'luks'),
  10. join_paths(meson.source_root(), 'src', 'pins', 'tang'),
  11. join_paths(meson.source_root(), 'src', 'pins', 'tpm2'),
  12. meson.current_source_dir(),
  13. meson.current_build_dir(),
  14. join_paths(meson.build_root(), 'src'),
  15. join_paths(meson.build_root(), 'src', 'luks'),
  16. separator: ':'
  17. )
  18. test('bind-wrong-pass-luks1', find_program('bind-wrong-pass-luks1'), env: env)
  19. test('bind-luks1', find_program('bind-luks1'), env: env)
  20. test('unbind-unbound-slot-luks1', find_program('unbind-unbound-slot-luks1'), env: env)
  21. test('unbind-luks1', find_program('unbind-luks1'), env: env)
  22. test('bind-key-file-non-interactive', find_program('bind-key-file-non-interactive-luks1'), env: env)
  23. test('bind-pass-with-newline', find_program('bind-pass-with-newline-luks1'), env: env)
  24. test('bind-pass-with-newline-keyfile', find_program('bind-pass-with-newline-keyfile-luks1'), env: env)
  25. # Bug #70.
  26. test('bind-already-used-luksmeta-slot', find_program('bind-already-used-luksmeta-slot'), env: env, timeout: 60)
  27. # LUKS2 tests go here, and they get included if we get support for it, based
  28. # on the cryptsetup version.
  29. # Binding LUKS2 takes longer, so timeout is increased for a few tests.
  30. if luksmeta_data.get('OLD_CRYPTSETUP') == '0'
  31. test('bind-wrong-pass-luks2', find_program('bind-wrong-pass-luks2'), env: env)
  32. test('bind-luks2', find_program('bind-luks2'), env: env, timeout: 60)
  33. test('unbind-unbound-slot-luks2', find_program('unbind-unbound-slot-luks2'), env: env)
  34. test('unbind-luks2', find_program('unbind-luks2'), env: env, timeout: 60)
  35. endif