Optimize circleCI config (#2807)
Optimize circleCI config (#2807)

* Optimize circleCI config

- share and reuse commands where possible
- set rename build_container_config as defaults
  to following convention
- rely on bundle commandline options
  instead of bundle env vars, for simplicity
- combine brakeman, rubocop and jasmine tests
  to save on container use/hogging
- Add dependency restore to each test job
  rely on common circleCI caching instead of using
  persisted workspaces
- Separate tmp dir creation
  for clarity
- Only attach workspaces as and when required
- Run standard brakeman
  rather than rake, as more robust and more verbose
  output
- Split rspec by default (name)
  Remove unused --split-by=timings. need
  to store test results for timings to work
  and the default of name will suffice for now.
- Split features
  to improve overall test suite speed
- Add parallelism of 3 to rspec
  to get overall test time down to ~8

* Sum coverage from parallel rspec runs

parallel running containers create
their own simplecov results which
need to be summed for upload to
codeclimate.

* Naming and spacing tweaks

ministryofjustice/advocate-defence-payments,ministryofjustice/advocate-defence-payments,ministryofjustice/advocate-defence-payments,ministryofjustice/advocate-defence-payments