Skip to content

Commit bd1c615

Browse files
committed
Move str test from expr-if.rs to expr-if-box.rs in preperation for breaking that code path.
1 parent d631f29 commit bd1c615

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/test/run-pass/expr-if-box.rs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@ fn test_box() {
99
check (*res == 100);
1010
}
1111

12+
fn test_str() {
13+
auto res = if (true) { "happy" } else { "sad" };
14+
check (res == "happy");
15+
}
16+
1217
fn main() {
1318
test_box();
14-
}
19+
test_str();
20+
}

src/test/run-pass/expr-if.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,6 @@ fn test_if_as_block_result() {
8080
check (res);
8181
}
8282

83-
fn test_str() {
84-
auto res = if (true) { "happy" } else { "sad" };
85-
check (res == "happy");
86-
}
87-
8883
fn main() {
8984
test_if();
9085
test_else();
@@ -94,5 +89,4 @@ fn main() {
9489
test_inferrence();
9590
test_if_as_if_condition();
9691
test_if_as_block_result();
97-
test_str();
9892
}

0 commit comments

Comments
 (0)