From b1eb156eb4ac5168ae1d465da58f35d59d155a4f Mon Sep 17 00:00:00 2001 From: Mollemoll Date: Wed, 15 May 2024 11:25:28 +0200 Subject: [PATCH] fix: naming of Hmrc --- src/gb_vat/hmrc.rs | 10 +++++----- src/gb_vat/mod.rs | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/gb_vat/hmrc.rs b/src/gb_vat/hmrc.rs index 386beb8..e1dbf1b 100644 --- a/src/gb_vat/hmrc.rs +++ b/src/gb_vat/hmrc.rs @@ -11,9 +11,9 @@ use crate::verification::{Verification, VerificationResponse, VerificationStatus static BASE_URI: &'static str = "https://api.service.hmrc.gov.uk/organisations/vat/check-vat-number/lookup"; #[derive(Debug)] -pub struct HMRC; +pub struct Hmrc; -impl Verifier for HMRC { +impl Verifier for Hmrc { fn make_request(&self, tax_id: &TaxId) -> Result { let client = reqwest::blocking::Client::new(); let res = client @@ -86,7 +86,7 @@ mod tests { }"#.to_string() ); - let verifier = HMRC; + let verifier = Hmrc; let verification = verifier.parse_response(response).unwrap(); assert_eq!(verification.status(), &VerificationStatus::Verified); @@ -114,7 +114,7 @@ mod tests { }"#.to_string() ); - let verifier = HMRC; + let verifier = Hmrc; let verification = verifier.parse_response(response).unwrap(); assert_eq!(verification.status(), &VerificationStatus::Unverified); @@ -133,7 +133,7 @@ mod tests { }"#.to_string() ); - let verifier = HMRC; + let verifier = Hmrc; let verification = verifier.parse_response(response).unwrap(); assert_eq!(verification.status(), &VerificationStatus::Unavailable); diff --git a/src/gb_vat/mod.rs b/src/gb_vat/mod.rs index 960e2be..fe6ba42 100644 --- a/src/gb_vat/mod.rs +++ b/src/gb_vat/mod.rs @@ -36,7 +36,7 @@ impl TaxIdType for GbVat { } fn verifier(&self) -> Box { - Box::new(hmrc::HMRC) + Box::new(hmrc::Hmrc) } }