Issue #2881012 by Lendude, dawehner, michielnugter: Move generatePermutations out of testbase into a trait