File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1028,7 +1028,15 @@ end
10281028 # We'll use jobs + 1 workers because one will crash.
10291029 @test ParallelTestRunner. ID_COUNTER[] == old_id_counter + jobs + 1
10301030 end
1031+ end
10311032
1033+ # This testset should always be the last one, don't add anything after this.
1034+ # We want to make sure there are no running workers at the end of the tests.
1035+ @testset " no workers running" begin
1036+ children = _count_child_pids ()
1037+ if children >= 0
1038+ @test children == 0
1039+ end
10321040end
10331041
10341042end
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ function _count_child_pids(pid = getpid())
1414 # because it's spawned by the current process, in that case we subtract
1515 # one to always exclude it, otherwise if we're getting the number of
1616 # children of another process we start from 0.
17- count = pid == getpid () : - 1 : 0
17+ count = pid == getpid () ? - 1 : 0
1818 for line in lines
1919 m = match (r" *(\d +) +(\d +)" , line)
2020 if ! isnothing (m)
You can’t perform that action at this time.
0 commit comments