File tree Expand file tree Collapse file tree 1 file changed +13
-11
lines changed Expand file tree Collapse file tree 1 file changed +13
-11
lines changed Original file line number Diff line number Diff line change @@ -1171,7 +1171,10 @@ fn doc_workspace_open_help_message() {
1171
1171
#[ cargo_test]
1172
1172
#[ cfg( not( windows) ) ] // `echo` may not be available
1173
1173
fn doc_extern_map_local ( ) {
1174
- assert ! ( is_nightly( ) ) ;
1174
+ if !is_nightly ( ) {
1175
+ // -Zextern-html-root-url is unstable
1176
+ return ;
1177
+ }
1175
1178
1176
1179
let p = project ( )
1177
1180
. file (
@@ -1183,21 +1186,20 @@ fn doc_extern_map_local() {
1183
1186
"# ,
1184
1187
)
1185
1188
. file ( "src/lib.rs" , "" )
1189
+ . file ( ".cargo/config.toml" , "doc.extern-map.std = 'local'" )
1186
1190
. build ( ) ;
1187
1191
1188
- p. change_file (
1189
- ".cargo/config.toml" ,
1190
- r#"
1191
- [doc.extern-map]
1192
- std = "local"
1193
- "# ,
1194
- ) ;
1195
-
1196
1192
p. cargo ( "doc -v --no-deps -Zrustdoc-map --open" )
1197
1193
. env ( "BROWSER" , "echo" )
1198
1194
. masquerade_as_nightly_cargo ( )
1199
- . with_stderr_contains ( "[..] Documenting foo v0.1.0 ([..])" )
1200
- . with_stderr_does_not_contain ( "warning: unused config key `doc.extern-map` [..]" )
1195
+ . with_stderr (
1196
+ "\
1197
+ [DOCUMENTING] foo v0.1.0 [..]
1198
+ [RUNNING] `rustdoc --crate-type lib --crate-name foo src/lib.rs [..]--crate-version 0.1.0`
1199
+ [FINISHED] [..]
1200
+ Opening [CWD]/target/doc/foo/index.html
1201
+ " ,
1202
+ )
1201
1203
. run ( ) ;
1202
1204
}
1203
1205
You can’t perform that action at this time.
0 commit comments