Skip to content

Commit

Permalink
fix: use array of custom tests instead of vec
Browse files Browse the repository at this point in the history
  • Loading branch information
nfejzic committed Sep 9, 2023
1 parent e5204c7 commit 1cb0637
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions core/tests/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,15 @@ macro_rules! test_fn {

fn main() {
let args = libtest_mimic::Arguments::from_args();
let snap_tests = blocks::test_block_snapshots();

let mut tests = snap_tests;
tests.append(&mut collect_tests());
let mut tests = blocks::test_block_snapshots();
tests.extend(collect_tests());

libtest_mimic::run(&args, tests).exit();
}

fn collect_tests() -> Vec<libtest_mimic::Trial> {
vec![
fn collect_tests() -> impl IntoIterator<Item = libtest_mimic::Trial> {
[
test_fn!(general::metadata::test__metadata__create_from_memory),
test_fn!(general::unimarkup::compile_empty_content),
]
Expand Down

0 comments on commit 1cb0637

Please sign in to comment.