diff --git a/test/test_asynchronous_process_fork.py b/test/test_asynchronous_process_fork.py index 6b73632..16f1439 100644 --- a/test/test_asynchronous_process_fork.py +++ b/test/test_asynchronous_process_fork.py @@ -28,6 +28,8 @@ raise Exception(mp_context.get_start_method()) except RuntimeError: # child process pass +else: + mp_context = multiprocessing.get_context() def not_decorated(argument, keyword_argument=0): diff --git a/test/test_asynchronous_process_forkserver.py b/test/test_asynchronous_process_forkserver.py index abffb65..a6c5877 100644 --- a/test/test_asynchronous_process_forkserver.py +++ b/test/test_asynchronous_process_forkserver.py @@ -28,6 +28,8 @@ raise Exception(mp_context.get_start_method()) except RuntimeError: # child process pass +else: + mp_context = multiprocessing.get_context() def not_decorated(argument, keyword_argument=0): diff --git a/test/test_asynchronous_process_spawn.py b/test/test_asynchronous_process_spawn.py index a9b8baf..af5c093 100644 --- a/test/test_asynchronous_process_spawn.py +++ b/test/test_asynchronous_process_spawn.py @@ -28,6 +28,8 @@ raise Exception(mp_context.get_start_method()) except RuntimeError: # child process pass +else: + mp_context = multiprocessing.get_context() def not_decorated(argument, keyword_argument=0): diff --git a/test/test_concurrent_process_fork.py b/test/test_concurrent_process_fork.py index f74c3ae..5d0dc5d 100644 --- a/test/test_concurrent_process_fork.py +++ b/test/test_concurrent_process_fork.py @@ -27,6 +27,8 @@ raise Exception(mp_context.get_start_method()) except RuntimeError: # child process pass +else: + mp_context = multiprocessing.get_context() def not_decorated(argument, keyword_argument=0): diff --git a/test/test_concurrent_process_forkserver.py b/test/test_concurrent_process_forkserver.py index f98100f..bb3f956 100644 --- a/test/test_concurrent_process_forkserver.py +++ b/test/test_concurrent_process_forkserver.py @@ -27,6 +27,8 @@ raise Exception(mp_context.get_start_method()) except RuntimeError: # child process pass +else: + mp_context = multiprocessing.get_context() def not_decorated(argument, keyword_argument=0): diff --git a/test/test_concurrent_process_spawn.py b/test/test_concurrent_process_spawn.py index 36409d0..56bb185 100644 --- a/test/test_concurrent_process_spawn.py +++ b/test/test_concurrent_process_spawn.py @@ -27,6 +27,8 @@ raise Exception(mp_context.get_start_method()) except RuntimeError: # child process pass +else: + mp_context = multiprocessing.get_context() def not_decorated(argument, keyword_argument=0):