Skip to content

Commit

Permalink
fix: unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
rruckley committed Feb 13, 2025
1 parent 6aa01fa commit a54b635
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/common/tmf_error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ use thiserror::Error;

#[derive(Debug,Error)]
pub enum TMFError {
#[error("Error: {0}")]
NoConnetion(String),
#[error("Error: {0}")]
#[error("TMFError: {0}")]
NoConnection(String),
#[error("TMFError: {0}")]
Unknown(String),
#[error("Error: {0}")]
#[error("TMFError: {0}")]
Serialization(String)
}

Expand All @@ -21,7 +21,7 @@ impl From<&str> for TMFError {

impl From<reqwest::Error> for TMFError {
fn from(value: reqwest::Error) -> Self {
TMFError::NoConnetion(value.to_string())
TMFError::NoConnection(value.to_string())
}
}

Expand All @@ -44,7 +44,7 @@ mod tests {
fn test_error_from_str() {
let err = TMFError::from("ThisIsAnError");

assert_eq!(err.to_string(),"Error: ThisIsAnError".to_string());
assert_eq!(err.to_string(),"TMFError: ThisIsAnError".to_string());
}

#[test]
Expand Down

0 comments on commit a54b635

Please sign in to comment.