Skip to content

Commit

Permalink
Stop checking that the graph produced by a dry run is equivalent
Browse files Browse the repository at this point in the history
This is too likely to cause spurious bounces on CI; what we run may be
dependent on what ran successfully before hand (e.g. RLS features with
Clippy), which makes this not tenable. There's no good way to ignore
specifically these problematic steps so we'll just ignore everything for
the time being. We still test that a dry run worked though so largely
this is the same from a ensure-that-tests-work perspective.

Eventually we'll want to undo this commit, though, to make our tests
more accurate.
  • Loading branch information
Mark-Simulacrum committed Apr 3, 2018
1 parent 0ce5cf0 commit 184d3bc
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions src/bootstrap/lib.rs
Expand Up @@ -416,22 +416,14 @@ impl Build {
}

if !self.config.dry_run {
let dry_graph = {
{
self.config.dry_run = true;
let builder = builder::Builder::new(&self);
builder.execute_cli()
};
builder.execute_cli();
}
self.config.dry_run = false;
let builder = builder::Builder::new(&self);
let act_graph = builder.execute_cli();
assert_eq!(dry_graph.raw_nodes().iter().map(|i| &i.weight).collect::<Vec<_>>(),
act_graph.raw_nodes().iter().map(|i| &i.weight).collect::<Vec<_>>());
assert_eq!(dry_graph.raw_edges()
.iter().map(|i| (&dry_graph[i.source()], &dry_graph[i.target()], &i.weight))
.collect::<Vec<_>>(),
act_graph.raw_edges()
.iter().map(|i| (&act_graph[i.source()], &act_graph[i.target()], &i.weight))
.collect::<Vec<_>>());
builder.execute_cli();
} else {
let builder = builder::Builder::new(&self);
let _ = builder.execute_cli();
Expand Down

0 comments on commit 184d3bc

Please sign in to comment.