-
Notifications
You must be signed in to change notification settings - Fork 10
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
Fixed Dutch postal code validation. #74
Conversation
This resolves issue #73 - Disabled left-padding on Dutch postal codes. - Dutch postal codes can not start with a `0`. - Dutch postal codes can not contain `SA`, `SS` or `SD`. I see this is a generated file, but it's origins are unclear to me. If this should be implemented elsewhere, I'm happy to add another pull request. :-)
Apparently there are some unit tests in place that consider postal codes starting with a |
Sorry I missed your comments here, the correct place for the changes would be https://github.com/Cimpress-MCP/PostalCodes.Net/blob/master/src/countries/NL.json About the unit tests, feel free to update the incorrect postal codes in the test cases. I guess it's only the ones starting with 0 right? |
Thank you, @mmaruniak. I'll have a look at that. |
Regenerated test files.
(I'm not so sure about lines 11 & 12)
…sor implementation Apparently the "GeneratePredecessor" implementation can't reliably handle generating a predecessor that wraps back to something other than 0. 9999 -> 0000 works fine, but when it has to wrap from 9999 -> 1000 and back, it doesn't know how to handle that. I've disabled those test cases for now, as I'm not sure if I can fix them or how that would be done.
@mmaruniak: Build succeeded now, but I had to disable some tests that deal with predecessors. The method that generates a predecessor doesn't seem to be able to handle numeric values that don't wrap around to 0. I'm not sure how to fix that. |
src/PostalCodes.UnitTests/CountrySpecificPostalCodes/NLPostalCodeManualTests.cs
Show resolved
Hide resolved
src/PostalCodes.UnitTests/CountrySpecificPostalCodes/NLPostalCodeManualTests.cs
Outdated
Show resolved
Hide resolved
src/PostalCodes.UnitTests/CountrySpecificPostalCodes/NLPostalCodeManualTests.cs
Show resolved
Hide resolved
Remvoed some commented-out test cases.
Done, @mmaruniak. Thanks for the review! |
Merge feature #74 into release 2.1.0
@mmaruniak: Thanks for the merge. Do you happen to have some information on if / when a new version of the package can be released? |
Sorry @Cerbrus we have a bit of a situation here. The API keys to publish the artifact are expired so I didn't manage to release it. And we are in process of transferring the repository to new owners so I'll get in touch with the original owners and try to fix the API keys |
Oh wow, yea, I can imagine that taking some time. Thanks for the update! |
@mmaruniak Is this still on the roadmap somewhere? |
Right, sorry for not getting back to this sooner @Cerbrus . I am out for a week but I have transferred this repository to @pavelsavara . Pavel could you please try releasing this? I think we only need to trigger a build on the 2.1.0 release branch now |
We just released version 3 for .NET standard 2.0. Is that ok for you ? |
Hi @pavelsavara I had to update the target framework of our project to 4.6.1, but that had to happen some day, any way. Thanks for the update (@mmaruniak as well)! |
This reverts commit a46a9d7.
This resolves issue #73
0
.SA
,SS
orSD
.I see this is a generated file, but it's origins are unclear to me. If this should be implemented elsewhere, I'm happy to add another pull request. :-)