Logs and tests (#3247)

* Add command name to err

* Add var name to error message

* Add test for def comment in test
This commit is contained in:
Leonhard Kipp
2021-04-02 00:09:33 +02:00
committed by GitHub
parent 0fe6c7c558
commit f03f1949bf
3 changed files with 27 additions and 2 deletions

View File

@ -264,7 +264,7 @@ fn evaluate_reference(name: &str, ctx: &EvaluationContext, tag: Tag) -> Result<V
Some(v) => Ok(v),
None => Err(ShellError::labeled_error(
"Variable not in scope",
"unknown variable",
format!("unknown variable: {}", x),
tag.span,
)),
},