File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed
Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -223,9 +223,20 @@ def run(test: Test) -> TestResult:
223223 time = timedelta (seconds = end - start )
224224 return TestResult (test = test , passed = passed , time = time )
225225
226- # with ThreadPoolExecutor() as executor:
227- # results = executor.map(run, tests)
228- results = [run (test ) for test in tests ]
226+ times = {
227+ "curl" : timedelta (minutes = 3 , seconds = 26 ),
228+ "json-c" : timedelta (seconds = 23 ),
229+ "libxml2" : timedelta (minutes = 1 , seconds = 39 ),
230+ "lua" : timedelta (seconds = 37 ),
231+ "nginx" : timedelta (minutes = 1 , seconds = 18 ),
232+ "python2" : timedelta (minutes = 3 , seconds = 56 ),
233+ "zstd" : timedelta (seconds = 47 ),
234+ }
235+ # run longer tests first
236+ tests .sort (key = lambda test : - times [test .name ])
237+
238+ with ThreadPoolExecutor () as executor :
239+ results = executor .map (run , tests , chunksize = 1 )
229240
230241 for result in results :
231242 print (f"{ result .test .name } took { result .time } " )
You can’t perform that action at this time.
0 commit comments