Skip to content

Commit 63cc3c7

Browse files
committed
test llvm_out behaviour
Signed-off-by: onur-ozkan <[email protected]>
1 parent 7fb4512 commit 63cc3c7

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

Diff for: src/bootstrap/src/core/builder/tests.rs

+17
Original file line numberDiff line numberDiff line change
@@ -524,6 +524,23 @@ mod dist {
524524
);
525525
}
526526

527+
#[test]
528+
fn llvm_out_behaviour() {
529+
let mut config = configure(&["A"], &["B"]);
530+
config.llvm_from_ci = true;
531+
let build = Build::new(config.clone());
532+
533+
let target = TargetSelection::from_user("A");
534+
assert!(build.llvm_out(target).ends_with("ci-llvm"));
535+
let target = TargetSelection::from_user("B");
536+
assert!(build.llvm_out(target).ends_with("llvm"));
537+
538+
config.llvm_from_ci = false;
539+
let build = Build::new(config.clone());
540+
let target = TargetSelection::from_user("A");
541+
assert!(build.llvm_out(target).ends_with("llvm"));
542+
}
543+
527544
#[test]
528545
fn build_with_empty_host() {
529546
let config = configure(&[], &["C"]);

0 commit comments

Comments
 (0)