Skip to content

Commit

Permalink
compiletest: Fix a couple of test re-run issues
Browse files Browse the repository at this point in the history
* Re-run rustdoc tests if rustdoc or htmldocck.py was updated.
* Put stamp files in the correct subdirectories to avoid clashes when
the file names match but the subdirectory doesn't.
  • Loading branch information
ollie27 committed Nov 10, 2017
1 parent d5ff0e6 commit ec15924
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/tools/compiletest/src/main.rs
Expand Up @@ -491,6 +491,7 @@ fn stamp(config: &Config, testpaths: &TestPaths) -> PathBuf {
config.stage_id);
config.build_base.canonicalize()
.unwrap_or_else(|_| config.build_base.clone())
.join(&testpaths.relative_dir)
.join(stamp_name)
}

Expand Down Expand Up @@ -522,6 +523,10 @@ fn up_to_date(config: &Config, testpaths: &TestPaths, props: &EarlyProps) -> boo
let lib = lib.unwrap();
inputs.push(mtime(&lib.path()));
}
if let Some(ref rustdoc_path) = config.rustdoc_path {
inputs.push(mtime(&rustdoc_path));
inputs.push(mtime(&rust_src_dir.join("src/etc/htmldocck.py")));
}
inputs.iter().any(|input| *input > stamp)
}

Expand Down

0 comments on commit ec15924

Please sign in to comment.