Fix some bugs that occurred when running tests on Ada. Should be soon also merged to develop to enable the corresponding runs.