Fix integration tests to work with the new superbuild

Change log:
* Close file descriptors later in the process
5 jobs for devel in 8 minutes and 11 seconds (queued for 2 seconds)
Status Name Job ID Coverage
  Static Analysis
passed Format #5584
docker

00:00:12

passed Lint #5585
docker

00:04:02

 
  Build
passed Documentation #5586
docker

00:00:19

 
  Test
passed Authorisation Disabled #5588
docker

00:01:46

passed Default #5587
docker

00:01:51