Fix parallel testing on ci
This merge request fixes parallel CI builds in the most simple way.
For Linux host, /dev/shm
is used to store the test database and prefix to speedup tests execution.
However, on the Gitlab CI, the same machine may run several builds in parallel which means that one run might overwrite data from another one.
In order to avoid that two solutions are possible:
- Use the database and prefix "in place" (i.e. in the same folder as the code)
- Use the various Gitlab provided environment variables to build a path in
/dev/shm
to ensure each build has its data in its own directory
The first solution was chosen has it is the easiest to put in place.
Merge request reports
Activity
added enhancement label
cc @andre.anjos
mentioned in commit a6edb816
RAM disk speed VS good old spinning disk speed or NFS disk.
On my old machine the tests setup became way faster especially with regard to the beat/beat.cmdline> tests which were re-creating the whole database/prefix for each and every test before I optimized the SQLite database base file management.
IIRC, the test time was cut at least in half. It will be less relevant on machine with SSD disks.