@@ -257,31 +257,6 @@ fn parse_config_download_rustc_at(path: &Path, download_rustc: &str, ci: bool) -
257257 )
258258}
259259
260- mod defaults {
261- use pretty_assertions:: assert_eq;
262-
263- use super :: { TEST_TRIPLE_1 , TEST_TRIPLE_2 , configure, first, run_build} ;
264- use crate :: Config ;
265- use crate :: core:: builder:: * ;
266-
267- #[ test]
268- fn doc_default ( ) {
269- let mut config = configure ( "doc" , & [ TEST_TRIPLE_1 ] , & [ TEST_TRIPLE_1 ] ) ;
270- config. compiler_docs = true ;
271- config. cmd = Subcommand :: Doc { open : false , json : false } ;
272- let mut cache = run_build ( & [ ] , config) ;
273- let a = TargetSelection :: from_user ( TEST_TRIPLE_1 ) ;
274-
275- // error_index_generator uses stage 0 to share rustdoc artifacts with the
276- // rustdoc tool.
277- assert_eq ! ( first( cache. all:: <doc:: ErrorIndex >( ) ) , & [ doc:: ErrorIndex { target: a } , ] ) ;
278- assert_eq ! (
279- first( cache. all:: <tool:: ErrorIndex >( ) ) ,
280- & [ tool:: ErrorIndex { compiler: Compiler :: new( 1 , a) } ]
281- ) ;
282- }
283- }
284-
285260mod dist {
286261 use pretty_assertions:: assert_eq;
287262
@@ -309,28 +284,6 @@ mod dist {
309284 let target = TargetSelection :: from_user ( TEST_TRIPLE_1 ) ;
310285 assert ! ( build. llvm_out( target) . ends_with( "llvm" ) ) ;
311286 }
312-
313- #[ test]
314- fn doc_ci ( ) {
315- let mut config = configure ( & [ TEST_TRIPLE_1 ] , & [ TEST_TRIPLE_1 ] ) ;
316- config. compiler_docs = true ;
317- config. cmd = Subcommand :: Doc { open : false , json : false } ;
318- let build = Build :: new ( config) ;
319- let mut builder = Builder :: new ( & build) ;
320- builder. run_step_descriptions ( & Builder :: get_step_descriptions ( Kind :: Doc ) , & [ ] ) ;
321- let a = TargetSelection :: from_user ( TEST_TRIPLE_1 ) ;
322-
323- // error_index_generator uses stage 1 to share rustdoc artifacts with the
324- // rustdoc tool.
325- assert_eq ! (
326- first( builder. cache. all:: <doc:: ErrorIndex >( ) ) ,
327- & [ doc:: ErrorIndex { target: a } , ]
328- ) ;
329- assert_eq ! (
330- first( builder. cache. all:: <tool:: ErrorIndex >( ) ) ,
331- & [ tool:: ErrorIndex { compiler: Compiler :: new( 1 , a) } ]
332- ) ;
333- }
334287}
335288
336289mod sysroot_target_dirs {
@@ -888,6 +841,19 @@ mod snapshot {
888841 " ) ;
889842 }
890843
844+ #[ test]
845+ fn build_error_index ( ) {
846+ let ctx = TestCtx :: new ( ) ;
847+ insta:: assert_snapshot!(
848+ ctx. config( "build" )
849+ . path( "error_index_generator" )
850+ . render_steps( ) , @r"
851+ [build] llvm <host>
852+ [build] rustc 0 <host> -> rustc 1 <host>
853+ [build] rustc 0 <host> -> error-index 1 <host>
854+ " ) ;
855+ }
856+
891857 #[ test]
892858 fn build_bootstrap_tool_no_explicit_stage ( ) {
893859 let ctx = TestCtx :: new ( ) ;
@@ -1032,6 +998,8 @@ mod snapshot {
1032998 [build] rustc 1 <host> -> rustc 2 <host>
1033999 [build] rustdoc 2 <host>
10341000 [doc] std 2 <host> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
1001+ [build] rustc 1 <host> -> error-index 2 <host>
1002+ [doc] rustc 1 <host> -> error-index 2 <host>
10351003 [build] rustc 2 <host> -> std 2 <host>
10361004 [build] rustc 0 <host> -> LintDocs 1 <host>
10371005 [build] rustc 0 <host> -> RustInstaller 1 <host>
@@ -1074,6 +1042,8 @@ mod snapshot {
10741042 [build] rustc 1 <host> -> LlvmBitcodeLinker 2 <host>
10751043 [build] rustdoc 2 <host>
10761044 [doc] std 2 <host> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
1045+ [build] rustc 1 <host> -> error-index 2 <host>
1046+ [doc] rustc 1 <host> -> error-index 2 <host>
10771047 [build] rustc 2 <host> -> std 2 <host>
10781048 [build] rustc 0 <host> -> LintDocs 1 <host>
10791049 [build] rustc 0 <host> -> RustInstaller 1 <host>
@@ -1114,6 +1084,8 @@ mod snapshot {
11141084 [build] rustdoc 2 <host>
11151085 [doc] std 2 <host> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
11161086 [doc] std 2 <target1> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
1087+ [build] rustc 1 <host> -> error-index 2 <host>
1088+ [doc] rustc 1 <host> -> error-index 2 <host>
11171089 [build] rustc 2 <host> -> std 2 <host>
11181090 [build] rustc 0 <host> -> LintDocs 1 <host>
11191091 [build] rustc 0 <host> -> RustInstaller 1 <host>
@@ -1150,18 +1122,22 @@ mod snapshot {
11501122 [build] rustc 1 <host> -> rustc 2 <host>
11511123 [build] rustdoc 2 <host>
11521124 [doc] std 2 <host> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
1125+ [build] rustc 1 <host> -> error-index 2 <host>
1126+ [doc] rustc 1 <host> -> error-index 2 <host>
1127+ [build] llvm <target1>
1128+ [build] rustc 1 <host> -> std 1 <target1>
1129+ [build] rustc 1 <host> -> rustc 2 <target1>
1130+ [build] rustc 1 <host> -> error-index 2 <target1>
1131+ [doc] rustc 1 <host> -> error-index 2 <target1>
11531132 [build] rustc 2 <host> -> std 2 <host>
11541133 [build] rustc 0 <host> -> LintDocs 1 <host>
1155- [build] rustc 1 <host> -> std 1 <target1>
11561134 [build] rustc 2 <host> -> std 2 <target1>
11571135 [build] rustc 0 <host> -> RustInstaller 1 <host>
11581136 [dist] docs <host>
11591137 [doc] std 2 <host> crates=[]
11601138 [dist] mingw <host>
11611139 [build] rustc 0 <host> -> GenerateCopyright 1 <host>
11621140 [dist] rustc <host>
1163- [build] llvm <target1>
1164- [build] rustc 1 <host> -> rustc 2 <target1>
11651141 [build] rustdoc 2 <target1>
11661142 [dist] rustc <target1>
11671143 [dist] rustc 1 <host> -> std 1 <host>
@@ -1188,9 +1164,15 @@ mod snapshot {
11881164 [build] rustdoc 2 <host>
11891165 [doc] std 2 <host> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
11901166 [doc] std 2 <target1> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
1167+ [build] rustc 1 <host> -> error-index 2 <host>
1168+ [doc] rustc 1 <host> -> error-index 2 <host>
1169+ [build] llvm <target1>
1170+ [build] rustc 1 <host> -> std 1 <target1>
1171+ [build] rustc 1 <host> -> rustc 2 <target1>
1172+ [build] rustc 1 <host> -> error-index 2 <target1>
1173+ [doc] rustc 1 <host> -> error-index 2 <target1>
11911174 [build] rustc 2 <host> -> std 2 <host>
11921175 [build] rustc 0 <host> -> LintDocs 1 <host>
1193- [build] rustc 1 <host> -> std 1 <target1>
11941176 [build] rustc 2 <host> -> std 2 <target1>
11951177 [build] rustc 0 <host> -> RustInstaller 1 <host>
11961178 [dist] docs <host>
@@ -1201,8 +1183,6 @@ mod snapshot {
12011183 [dist] mingw <target1>
12021184 [build] rustc 0 <host> -> GenerateCopyright 1 <host>
12031185 [dist] rustc <host>
1204- [build] llvm <target1>
1205- [build] rustc 1 <host> -> rustc 2 <target1>
12061186 [build] rustdoc 2 <target1>
12071187 [dist] rustc <target1>
12081188 [dist] rustc 1 <host> -> std 1 <host>
@@ -1261,17 +1241,19 @@ mod snapshot {
12611241 [build] rustc 1 <host> -> WasmComponentLd 2 <host>
12621242 [build] rustdoc 2 <host>
12631243 [doc] std 2 <target1> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
1264- [build] rustc 2 <host> -> std 2 <host >
1244+ [build] llvm <target1 >
12651245 [build] rustc 1 <host> -> std 1 <target1>
1246+ [build] rustc 1 <host> -> rustc 2 <target1>
1247+ [build] rustc 1 <host> -> WasmComponentLd 2 <target1>
1248+ [build] rustc 1 <host> -> error-index 2 <target1>
1249+ [doc] rustc 1 <host> -> error-index 2 <target1>
1250+ [build] rustc 2 <host> -> std 2 <host>
12661251 [build] rustc 2 <host> -> std 2 <target1>
12671252 [build] rustc 0 <host> -> LintDocs 1 <host>
12681253 [build] rustc 0 <host> -> RustInstaller 1 <host>
12691254 [dist] docs <target1>
12701255 [doc] std 2 <target1> crates=[]
12711256 [dist] mingw <target1>
1272- [build] llvm <target1>
1273- [build] rustc 1 <host> -> rustc 2 <target1>
1274- [build] rustc 1 <host> -> WasmComponentLd 2 <target1>
12751257 [build] rustdoc 2 <target1>
12761258 [build] rustc 1 <host> -> rust-analyzer-proc-macro-srv 2 <target1>
12771259 [build] rustc 0 <host> -> GenerateCopyright 1 <host>
@@ -1651,6 +1633,25 @@ mod snapshot {
16511633 " ) ;
16521634 }
16531635
1636+ #[ test]
1637+ fn doc_all ( ) {
1638+ let ctx = TestCtx :: new ( ) ;
1639+ insta:: assert_snapshot!(
1640+ ctx. config( "doc" )
1641+ . render_steps( ) , @r"
1642+ [build] rustc 0 <host> -> UnstableBookGen 1 <host>
1643+ [build] rustc 0 <host> -> Rustbook 1 <host>
1644+ [build] llvm <host>
1645+ [build] rustc 0 <host> -> rustc 1 <host>
1646+ [build] rustdoc 1 <host>
1647+ [doc] std 1 <host> crates=[alloc,compiler_builtins,core,panic_abort,panic_unwind,proc_macro,rustc-std-workspace-core,std,std_detect,sysroot,test,unwind]
1648+ [build] rustc 0 <host> -> error-index 1 <host>
1649+ [doc] rustc 0 <host> -> error-index 1 <host>
1650+ [build] rustc 1 <host> -> std 1 <host>
1651+ [build] rustc 0 <host> -> LintDocs 1 <host>
1652+ " ) ;
1653+ }
1654+
16541655 #[ test]
16551656 fn doc_library ( ) {
16561657 let ctx = TestCtx :: new ( ) ;
0 commit comments