diff --git a/script/test/test_proc.py b/script/test/test_proc.py index 8d9768b..a96a028 100644 --- a/script/test/test_proc.py +++ b/script/test/test_proc.py @@ -4,6 +4,7 @@ def f(name): print('hello', name) -p = Process(target=f, args=('bob',)) -p.start() -p.join() \ No newline at end of file +if __name__ == '__main__': + p = Process(target=f, args=('bob',)) + p.start() + p.join() \ No newline at end of file