# I have this code: def destroy old_store = mobile_application.store users_ids = [1,2] super UpdateLastUpdatesWorker.perform_async old_store.id, users_ids mobile_application.last_update = mobile_application.old_last_update mobile_application.save! end # tests pass def destroy old_store = mobile_application.store super UpdateLastUpdatesWorker.perform_async old_store.id mobile_application.last_update = mobile_application.old_last_update mobile_application.save! end # tests fails with "Failed to destroy the record" # If we edit the worker line with : UpdateLastUpdatesWorker.perform_async old_store.id # fail ! UpdateLastUpdatesWorker.perform_async old_store.id, [] # Tests pass !