Fix test assertions to work in both turbopack and webpack modes
Use regex alternation for error message patterns that differ between
bundlers, and only check turbopack-specific "Caused by" messages when
isTurbopack is true.
https://claude.ai/code/session_01FbM2UdVB9uCtaN2826xBp5