Skip to content

Commit

Permalink
Don't handle SIGINT in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
lionel- committed Sep 27, 2024
1 parent 2ff80e8 commit 7705cb0
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions crates/ark/src/sys/unix/interface.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,11 @@ pub fn setup_r(mut args: Vec<*mut c_char>) {

Rf_initialize_R(args.len() as i32, args.as_mut_ptr() as *mut *mut c_char);

// Initialize the signal blocks and handlers (like interrupts)
initialize_signal_handlers();
// Initialize the signal blocks and handlers (like interrupts).
// Don't do that in tests because that makes them uninterruptible.
if !harp::IS_TESTING {
initialize_signal_handlers();
}

// Mark R session as interactive
// (Should have also been set by call to `Rf_initialize_R()`)
Expand Down

0 comments on commit 7705cb0

Please sign in to comment.