@@ -25,6 +25,7 @@ use hyperlight_host::{GuestBinary, HyperlightError, MultiUseSandbox, Uninitializ
2525use hyperlight_testing:: simplelogger:: { LOGGER , SimpleLogger } ;
2626use hyperlight_testing:: { c_simple_guest_as_string, simple_guest_as_string} ;
2727use log:: LevelFilter ;
28+ use serial_test:: serial;
2829
2930pub mod common; // pub to disable dead_code warning
3031use crate :: common:: { new_uninit, new_uninit_c, new_uninit_rust} ;
@@ -293,6 +294,7 @@ fn interrupt_moved_sandbox() {
293294/// The ABA-problem is solved by clearing CANCEL bit at the start of each VirtualCPU::run() call.
294295#[ test]
295296#[ cfg( target_os = "linux" ) ]
297+ #[ serial( thread_heavy) ]
296298fn interrupt_custom_signal_no_and_retry_delay ( ) {
297299 let mut config = SandboxConfiguration :: default ( ) ;
298300 config. set_interrupt_vcpu_sigrtmin_offset ( 0 ) . unwrap ( ) ;
@@ -315,8 +317,8 @@ fn interrupt_custom_signal_no_and_retry_delay() {
315317 let thread = thread:: spawn ( move || {
316318 for _ in 0 ..NUM_ITERS {
317319 // wait for the guest call to start
318- thread:: sleep ( Duration :: from_millis ( 1000 ) ) ;
319- interrupt_handle. kill ( ) ;
320+ thread:: sleep ( Duration :: from_millis ( 3000 ) ) ;
321+ assert ! ( interrupt_handle. kill( ) ) ;
320322 }
321323 } ) ;
322324
@@ -864,6 +866,7 @@ fn test_if_guest_is_able_to_get_string_return_values_from_host() {
864866/// - Calls we did NOT choose to kill NEVER return ExecutionCanceledByHost
865867/// - We get a mix of killed and non-killed outcomes (not 100% or 0%)
866868#[ test]
869+ #[ serial( thread_heavy) ]
867870fn interrupt_random_kill_stress_test ( ) {
868871 // Wrapper to hold a sandbox and its snapshot together
869872 struct SandboxWithSnapshot {
@@ -1334,6 +1337,7 @@ fn interrupt_random_kill_stress_test() {
13341337///
13351338/// **Failure Condition:** If this test hangs, it means `kill()` failed to stop the guest, leaving it spinning forever.
13361339#[ test]
1340+ #[ serial( thread_heavy) ]
13371341fn interrupt_infinite_loop_stress_test ( ) {
13381342 use std:: sync:: { Arc , Barrier } ;
13391343 use std:: thread;
@@ -1421,6 +1425,7 @@ fn interrupt_infinite_loop_stress_test() {
14211425// mid-call and shares a thread ID with another sandbox, ensuring only the intended
14221426// VM is interrupted while bait sandboxes keep running.
14231427#[ test]
1428+ #[ serial( thread_heavy) ]
14241429fn interrupt_infinite_moving_loop_stress_test ( ) {
14251430 use std:: sync:: Arc ;
14261431 use std:: thread;
0 commit comments