-
Notifications
You must be signed in to change notification settings - Fork 1
TD-4624 Add regex validation of professional registration number field throughout the application #3355
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
Conversation
…d throughout the application
…d throughout the application
…d throughout the application
[TestCase( | ||
"01234_", | ||
"Invalid professional registration number format - Only alphanumeric characters (a-z, A-Z and 0-9) and hyphens (-) allowed" | ||
"Invalid professional registration number format. " + |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should assign this to a variable rather than repeating it in code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we assign the error string to a variable and reference it, rather than repeating it throughout code, please?
…/Features/TD-4624-Addregexvalidationofprofessionalregistrationnumberfieldthroughouttheapplication
Done |
JIRA link
https://hee-tis.atlassian.net/browse/TD-4624
Description
I swapped out the pattern string for the .NET regex that validates professional registration numbers.
I updated the test data to match the new pattern so the tests pass, and I revised the error message to reflect the updated allowed format.
Screenshots
I have:
Either:
Or: