api: prefetch test runs when handling builds
api: prefetch test runs when handling builds

Calculating the build metadata requires having the metadata for all of
its test runs. Prefetching the testruns, when rendering N builds,
replaces N additional queries (one per build) with just 1.

terceiro/squad,terceiro/squad,terceiro/squad,terceiro/squad