File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -1574,6 +1574,7 @@ impl<'a> Builder<'a> {
1574
1574
path : step. path ( self ) ,
1575
1575
// FIXME: top_stage might be higher than the stage of the step
1576
1576
stage : self . top_stage ,
1577
+ test_args : self . config . cmd . test_args ( ) . into_iter ( ) . map ( String :: from) . collect ( ) ,
1577
1578
} ;
1578
1579
// NOTE: don't hold onto this guard, it will cause a deadlock if the current step calls `ensure` recursively.
1579
1580
let old_instructions = CURRENT_INSTRUCTIONS
@@ -1614,6 +1615,7 @@ struct ReplicationStep {
1614
1615
name : & ' static str ,
1615
1616
path : PathBuf ,
1616
1617
stage : u32 ,
1618
+ test_args : Vec < String > ,
1617
1619
}
1618
1620
1619
1621
lazy_static ! {
@@ -1638,13 +1640,17 @@ pub(crate) extern "C" fn print_replication_steps() {
1638
1640
let _ = stdout. set_color ( & blue) ;
1639
1641
let _ = write ! ( stdout, "help" ) ;
1640
1642
let _ = stdout. reset ( ) ;
1641
- let _ = writeln ! (
1643
+ let _ = write ! (
1642
1644
stdout,
1643
- ": to replicate this failure, run `./x.py {} {} --stage {}` " ,
1645
+ ": to replicate this failure, run `./x.py {} {} --stage {}" ,
1644
1646
step. cmd,
1645
1647
step. path. display( ) ,
1646
1648
step. stage,
1647
1649
) ;
1650
+ for arg in step. test_args {
1651
+ let _ = write ! ( stdout, " --test-args \" {}\" " , arg) ;
1652
+ }
1653
+ let _ = writeln ! ( stdout, "`" ) ;
1648
1654
}
1649
1655
}
1650
1656
Original file line number Diff line number Diff line change @@ -1151,6 +1151,11 @@ impl Step for Compiletest {
1151
1151
run. never ( )
1152
1152
}
1153
1153
1154
+ fn path ( & self , _builder : & Builder < ' _ > ) -> PathBuf {
1155
+ // FIXME: it would be nice to suggest exactly the tests that fail, but that info isn't known without first running compiletest.
1156
+ self . path . into ( )
1157
+ }
1158
+
1154
1159
/// Executes the `compiletest` tool to run a suite of tests.
1155
1160
///
1156
1161
/// Compiles all tests with `compiler` for `target` with the specified
You can’t perform that action at this time.
0 commit comments