compile_tests.rs 428 B

1234567891011121314151617181920
  1. use std::process::Command;
  2. #[test]
  3. fn main() {
  4. let dir = env!("CARGO_MANIFEST_DIR");
  5. let tests = [
  6. "throw_and_catch",
  7. "catch_std_exception",
  8. "std_catch_exception",
  9. ];
  10. for test in tests {
  11. let status = Command::new("./check.sh")
  12. .current_dir(format!("{dir}/test_crates/{test}"))
  13. .status()
  14. .unwrap();
  15. assert!(status.success());
  16. }
  17. }