Fix some incorrect branch merge stuff

This commit is contained in:
Richard Feldman 2021-07-19 22:45:39 -04:00
parent c4616b6da8
commit f938c71272

View File

@ -302,234 +302,4 @@ mod cli_run {
assert_eq!(all_examples, std::collections::HashMap::default());
}
#[serial(hello_world)]
fn run_hello_world() {
check_output(
&example_file("hello-world", "Hello.roc"),
"hello-world",
&[],
"Hello, World!\n",
true,
);
}
#[test]
#[serial(hello_world)]
fn run_hello_world_optimized() {
check_output(
&example_file("hello-world", "Hello.roc"),
"hello-world",
&[],
"Hello, World!\n",
true,
);
}
#[test]
#[serial(quicksort)]
fn run_quicksort_not_optimized() {
check_output(
&example_file("quicksort", "Quicksort.roc"),
"quicksort",
&[],
"[0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2]\n",
true,
);
}
#[test]
#[serial(quicksort)]
fn run_quicksort_optimized() {
check_output(
&example_file("quicksort", "Quicksort.roc"),
"quicksort",
&["--optimize"],
"[0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2]\n",
true,
);
}
#[test]
#[serial(quicksort)]
fn run_quicksort_optimized_valgrind() {
check_output(
&example_file("quicksort", "Quicksort.roc"),
"quicksort",
&["--optimize"],
"[0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2]\n",
true,
);
}
#[test]
#[serial(nqueens)]
fn run_nqueens_not_optimized() {
check_output_with_stdin(
&example_file("benchmarks", "NQueens.roc"),
"6",
"nqueens",
&[],
"4\n",
true,
);
}
#[test]
#[serial(cfold)]
fn run_cfold_not_optimized() {
check_output_with_stdin(
&example_file("benchmarks", "CFold.roc"),
"3",
"cfold",
&[],
"11 & 11\n",
true,
);
}
#[test]
#[serial(deriv)]
fn run_deriv_not_optimized() {
check_output_with_stdin(
&example_file("benchmarks", "Deriv.roc"),
"2",
"deriv",
&[],
"1 count: 6\n2 count: 22\n",
true,
);
}
#[test]
#[serial(deriv)]
fn run_rbtree_insert_not_optimized() {
check_output(
&example_file("benchmarks", "RBTreeInsert.roc"),
"rbtree-insert",
&[],
"Node Black 0 {} Empty Empty\n",
true,
);
}
#[test]
#[serial(deriv)]
fn run_rbtree_delete_not_optimized() {
check_output_with_stdin(
&example_file("benchmarks", "RBTreeDel.roc"),
"420",
"rbtree-del",
&[],
"30\n",
true,
);
}
#[test]
#[serial(astar)]
fn run_astar_optimized_1() {
check_output(
&example_file("benchmarks", "TestAStar.roc"),
"test-astar",
&[],
"True\n",
false,
);
}
#[test]
#[serial(base64)]
fn base64() {
check_output(
&example_file("benchmarks", "TestBase64.roc"),
"test-base64",
&[],
"encoded: SGVsbG8gV29ybGQ=\ndecoded: Hello World\n",
true,
);
}
#[test]
#[serial(closure)]
fn closure() {
check_output(
&example_file("benchmarks", "Closure.roc"),
"closure",
&[],
"",
true,
);
}
// #[test]
// #[serial(effect)]
// fn run_effect_unoptimized() {
// check_output(
// &example_file("effect", "Main.roc"),
// &[],
// "I am Dep2.str2\n",
// true,
// );
// }
#[test]
#[serial(multi_dep_str)]
fn run_multi_dep_str_unoptimized() {
check_output(
&fixture_file("multi-dep-str", "Main.roc"),
"multi-dep-str",
&[],
"I am Dep2.str2\n",
true,
);
}
#[test]
#[serial(multi_dep_str)]
fn run_multi_dep_str_optimized() {
check_output(
&fixture_file("multi-dep-str", "Main.roc"),
"multi-dep-str",
&["--optimize"],
"I am Dep2.str2\n",
true,
);
}
#[test]
#[serial(multi_dep_thunk)]
fn run_multi_dep_thunk_unoptimized() {
check_output(
&fixture_file("multi-dep-thunk", "Main.roc"),
"multi-dep-thunk",
&[],
"I am Dep2.value2\n",
true,
);
}
#[test]
#[serial(multi_dep_thunk)]
fn run_multi_dep_thunk_optimized() {
check_output(
&fixture_file("multi-dep-thunk", "Main.roc"),
"multi-dep-thunk",
&["--optimize"],
"I am Dep2.value2\n",
true,
);
}
#[test]
#[serial(effect)]
fn run_effect() {
check_output_with_stdin(
&example_file("effect", "Main.roc"),
"hello world how are you",
"effect-example",
&[],
"hello world how are you\n",
true,
);
}
}