Skip to content

Modifying failure messages to be consistent with mismatch message #2349

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions tests/system.rs
Original file line number Diff line number Diff line change
Expand Up @@ -651,14 +651,16 @@ impl ConfigCodeBlock {

if self.config_name.is_none() {
write_message(format!(
"configuration name not found for block beginning at line {}",
"No configuration name for {}:{}",
CONFIGURATIONS_FILE_NAME,
self.code_block_start.unwrap()
));
return false;
}
if self.config_value.is_none() {
write_message(format!(
"configuration value not found for block beginning at line {}",
"No configuration value for {}:{}",
CONFIGURATIONS_FILE_NAME,
self.code_block_start.unwrap()
));
return false;
Expand All @@ -669,9 +671,9 @@ impl ConfigCodeBlock {
fn has_parsing_errors(&self, error_summary: Summary) -> bool {
if error_summary.has_parsing_errors() {
write_message(format!(
"\u{261d}\u{1f3fd} Failed to format block starting at Line {} in {}",
self.code_block_start.unwrap(),
CONFIGURATIONS_FILE_NAME
"\u{261d}\u{1f3fd} Cannot format {}:{}",
CONFIGURATIONS_FILE_NAME,
self.code_block_start.unwrap()
));
return true;
}
Expand Down