Skip to content

Commit e05a509

Browse files
committed
adapt bootstrap tests to new std design
Signed-off-by: onur-ozkan <[email protected]>
1 parent e1b2ffe commit e05a509

File tree

1 file changed

+3
-22
lines changed

1 file changed

+3
-22
lines changed

src/bootstrap/src/core/builder/tests.rs

Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ fn alias_and_path_for_library() {
198198
configure("doc", &[TEST_TRIPLE_1], &[TEST_TRIPLE_1]),
199199
);
200200
assert_eq!(first(cache.all::<doc::Std>()), &[
201-
doc_std!(TEST_TRIPLE_1 => TEST_TRIPLE_1, stage = 0)
201+
doc_std!(TEST_TRIPLE_1 => TEST_TRIPLE_1, stage = 1)
202202
]);
203203
}
204204

@@ -264,25 +264,6 @@ mod defaults {
264264
],);
265265
}
266266

267-
#[test]
268-
fn build_stage_0() {
269-
let config = Config { stage: 0, ..configure("build", &[TEST_TRIPLE_1], &[TEST_TRIPLE_1]) };
270-
let mut cache = run_build(&[], config);
271-
272-
let a = TargetSelection::from_user(TEST_TRIPLE_1);
273-
assert_eq!(first(cache.all::<compile::Std>()), &[
274-
std!(TEST_TRIPLE_1 => TEST_TRIPLE_1, stage = 0)
275-
]);
276-
assert!(!cache.all::<compile::Assemble>().is_empty());
277-
assert_eq!(
278-
first(cache.all::<tool::Rustdoc>()),
279-
// This is the beta rustdoc.
280-
// Add an assert here to make sure this is the only rustdoc built.
281-
&[tool::Rustdoc { compiler: Compiler { host: a, stage: 0 } }],
282-
);
283-
assert!(cache.all::<compile::Rustc>().is_empty());
284-
}
285-
286267
#[test]
287268
fn build_cross_compile() {
288269
let config = Config {
@@ -332,13 +313,13 @@ mod defaults {
332313
// rustdoc tool.
333314
assert_eq!(first(cache.all::<doc::ErrorIndex>()), &[doc::ErrorIndex { target: a },]);
334315
assert_eq!(first(cache.all::<tool::ErrorIndex>()), &[tool::ErrorIndex {
335-
compiler: Compiler { host: a, stage: 0 }
316+
compiler: Compiler { host: a, stage: 1 }
336317
}]);
337318
// docs should be built with the beta compiler, not with the stage0 artifacts.
338319
// recall that rustdoc is off-by-one: `stage` is the compiler rustdoc is _linked_ to,
339320
// not the one it was built by.
340321
assert_eq!(first(cache.all::<tool::Rustdoc>()), &[tool::Rustdoc {
341-
compiler: Compiler { host: a, stage: 0 }
322+
compiler: Compiler { host: a, stage: 1 }
342323
},]);
343324
}
344325
}

0 commit comments

Comments
 (0)