compiletest/rmake: avoid double test directory for rmake.rs tests
This is important for other tests that have various things like modes, revisions and the like. These features are not supported in run-make tests, so we don't need the double layering.
This commit is contained in:
parent
c863525374
commit
2c867d0b5f
@ -760,8 +760,14 @@ pub fn output_testname_unique(
|
|||||||
/// test/revision should reside. Example:
|
/// test/revision should reside. Example:
|
||||||
/// /path/to/build/host-triple/test/ui/relative/testname.revision.mode/
|
/// /path/to/build/host-triple/test/ui/relative/testname.revision.mode/
|
||||||
pub fn output_base_dir(config: &Config, testpaths: &TestPaths, revision: Option<&str>) -> PathBuf {
|
pub fn output_base_dir(config: &Config, testpaths: &TestPaths, revision: Option<&str>) -> PathBuf {
|
||||||
output_relative_path(config, &testpaths.relative_dir)
|
// In run-make tests, constructing a relative path + unique testname causes a double layering
|
||||||
.join(output_testname_unique(config, testpaths, revision))
|
// since revisions are not supported, causing unnecessary nesting.
|
||||||
|
if config.mode == Mode::RunMake {
|
||||||
|
output_relative_path(config, &testpaths.relative_dir)
|
||||||
|
} else {
|
||||||
|
output_relative_path(config, &testpaths.relative_dir)
|
||||||
|
.join(output_testname_unique(config, testpaths, revision))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Absolute path to the base filename used as output for the given
|
/// Absolute path to the base filename used as output for the given
|
||||||
|
Loading…
x
Reference in New Issue
Block a user