Issue #3403382 by alexpott, Wim Leers: BuildTestBase makes assumptions it should not about the code layout (cherry picked from commit cbbe53da)