mirror of
https://github.com/Orange-OpenSource/hurl.git
synced 2024-11-23 00:44:55 +03:00
Move empty result warning.
This commit is contained in:
parent
9444d6a058
commit
bbdd0f9569
@ -76,7 +76,7 @@ fn main() {
|
||||
let current_dir = current_dir.as_path();
|
||||
let start = Instant::now();
|
||||
|
||||
let runs = run::run_seq(&opts.input_files, current_dir, &opts, &base_logger);
|
||||
let runs = run::run_seq(&opts.input_files, current_dir, &opts);
|
||||
let runs = match runs {
|
||||
Ok(r) => r,
|
||||
Err(CliError::IO(msg)) => exit_with_error(&msg, EXIT_ERROR_PARSING, &base_logger),
|
||||
|
@ -19,7 +19,6 @@ use crate::cli::options::CliOptions;
|
||||
use crate::cli::CliError;
|
||||
use crate::{cli, HurlRun};
|
||||
use hurl::runner::{HurlResult, Input};
|
||||
use hurl::util::logger::BaseLogger;
|
||||
use hurl::{output, runner};
|
||||
use std::path::Path;
|
||||
|
||||
@ -30,7 +29,6 @@ pub fn run_seq(
|
||||
files: &[Input],
|
||||
current_dir: &Path,
|
||||
options: &CliOptions,
|
||||
logger: &BaseLogger,
|
||||
) -> Result<Vec<HurlRun>, CliError> {
|
||||
let mut runs = vec![];
|
||||
|
||||
@ -63,8 +61,6 @@ pub fn run_seq(
|
||||
if let Err(e) = result {
|
||||
return Err(CliError::Runtime(e.to_string()));
|
||||
}
|
||||
} else {
|
||||
logger.warning(&format!("No entry have been executed for file {filename}"));
|
||||
}
|
||||
}
|
||||
if matches!(options.output_type, cli::OutputType::Json) {
|
||||
|
@ -131,6 +131,10 @@ pub fn run(
|
||||
&mut logger,
|
||||
);
|
||||
|
||||
if result.success && result.entries.last().is_none() {
|
||||
logger.warning(&format!("No entry have been executed for file {filename}"));
|
||||
}
|
||||
|
||||
progress.on_completed(&result, &mut logger.stderr);
|
||||
|
||||
Ok(result)
|
||||
|
Loading…
Reference in New Issue
Block a user