diff --git a/pydantic_extra_types/currency_code.py b/pydantic_extra_types/currency_code.py index 3c8e0a1..7767ae0 100644 --- a/pydantic_extra_types/currency_code.py +++ b/pydantic_extra_types/currency_code.py @@ -132,7 +132,7 @@ def _validate(cls, currency_symbol: str, _: core_schema.ValidationInfo) -> str: raise PydanticCustomError( 'InvalidCurrency', 'Invalid currency code.' - ' See https://en.wikipedia.org/wiki/ISO_4217. ' + ' See https://en.wikipedia.org/wiki/ISO_4217 . ' 'Bonds, testing and precious metals codes are not allowed.', ) return currency_symbol diff --git a/tests/test_currency_code.py b/tests/test_currency_code.py index d259a8d..78f54fe 100644 --- a/tests/test_currency_code.py +++ b/tests/test_currency_code.py @@ -56,7 +56,7 @@ def test_forbidden_everyday(forbidden_currency): ValidationError, match=re.escape( '1 validation error for CurrencyCheckingModel\ncurrency\n ' - 'Invalid currency code. See https://en.wikipedia.org/wiki/ISO_4217. ' + 'Invalid currency code. See https://en.wikipedia.org/wiki/ISO_4217 . ' 'Bonds, testing and precious metals codes are not allowed. ' f"[type=InvalidCurrency, input_value='{forbidden_currency}', input_type=str]" ),