Tests: Build config-dependent tests in the same config they run

The CPackComponentsForAll-*, GeneratorExpression, and
TestsWorkingDirectory tests all build binaries that they later
need to run or package for the tested configuration.  Tell the
'ctest --build-and-test' call to use the same configuration
for driving the build process.
Merge topic 'fix-config-dependent-tests' into next

0854d45b Tests: Build config-dependent tests in the same config they run