Fix Thread tests
What does this implement/fix?
The pipelines have been failing because one of the tests defines EIGEN_GEMM_THREADPOOL. This caused to be included early on in , before DeviceWrapper.h
I moved DeviceWrapper.h before the check for EIGEN_GEMM_THREADPOOL and the threading tests passed on my local machine.
I also captured some variables explicitly to stop the C++20 extension warnings about this
and capture defaults. This is verbose but I think the only way to not generate a warning in any version of the standard.