+static void test_turn_off_itself()
+{
+ XBT_INFO("%s: Launch a sleep(5), then saw off the branch it's sitting on", __func__);
+
+ simgrid::s4u::Actor::create("sleep5_restarted", all_hosts[1], []() {
+ assert_exit(true, 5);
+ simgrid::s4u::this_actor::sleep_for(5);
+ simgrid::s4u::this_actor::get_host()->turn_off();
+ xbt_die("I should be dead now");
+ });
+ simgrid::s4u::this_actor::sleep_for(9);
+ all_hosts[1]->turn_on();
+ XBT_INFO("Test %s is ending", __func__);
+}
+