Auto merge of #9037 - Swatinem:test-cwd, r=alexcrichton
Auto merge of #9037 - Swatinem:test-cwd, r=alexcrichton

Assert that tests are run in the crate directory

To avoid regressions to the test runtime directory, this asserts that
all test types (unit, integration, doctest) are executed in the crate
(manifest) directory, no matter where that crate is in relation to the
workspace root.

See #8992 / #8993

rustyhorde/cargo,nipunn1313/cargo,rust-lang/cargo,eminence/cargo,nipunn1313/cargo,rust-lang/cargo,rustyhorde/cargo,eminence/cargo,rustyhorde/cargo,rust-lang/cargo,rustyhorde/cargo,nipunn1313/cargo,eminence/cargo,nipunn1313/cargo,eminence/cargo,rust-lang/cargo