From 2fe4aaa10d5a6fd2ff6a65372c7064cdef7768f3 Mon Sep 17 00:00:00 2001 From: Casper Beyer Date: Thu, 20 May 2021 03:08:41 +0800 Subject: fix(cli): always allow documentation modules to be checked (#10581) --- cli/tools/test_runner.rs | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'cli') diff --git a/cli/tools/test_runner.rs b/cli/tools/test_runner.rs index de251947b..ddfad8199 100644 --- a/cli/tools/test_runner.rs +++ b/cli/tools/test_runner.rs @@ -331,14 +331,6 @@ pub async fn run_tests( filter: Option, concurrent_jobs: usize, ) -> Result { - if test_modules.is_empty() { - println!("No matching test modules found"); - if !allow_none { - std::process::exit(1); - } - return Ok(false); - } - if !doc_modules.is_empty() { let mut test_programs = Vec::new(); @@ -415,6 +407,13 @@ pub async fn run_tests( program_state.maybe_import_map.clone(), ) .await?; + } else if test_modules.is_empty() { + println!("No matching test modules found"); + if !allow_none { + std::process::exit(1); + } + + return Ok(false); } program_state -- cgit v1.2.3