Split by timing parallelism does not seem to balance out

parallelism
#1

It kind of seem to be getting worse as of late. We have run probably 20-30 builds with the imbalanced run time now, thinking it would improve but it does not seem to be.

export CI_TESTFILES_UNIT=$(circleci tests glob "test/**/*.js" | circleci tests split --split-by=timings)

0 Likes

#2

I have found out the reason.

It is because hooks are not reported in the timing report.

I’m using Node.js mocha.

0 Likes

#3

I am facing the same issue - did you manage to fix it?

0 Likes

#4

Yes I have.

For my issue, it was due to 2 things:

  1. Firstly, hooks are not included as part of the timing report. Some of my tests have pretty heavy hooks (before()) but fairly quick test, the time in hooks are not included.

  2. 2nd issue is that junit reporter is using full path in the timing report, whereas circleci tests split is using relative path. What we end up doing is to strip away the full paths from the report before storing it, e.g.: sed -i 's/\/home\/circleci\/repo\///g' junit/test-results.xml.

1 Like

closed #5

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.

0 Likes