Skip to content
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

refactor(location): allow postcode_by_state to take an array of patterns #3170

Open
wants to merge 1 commit into
base: next
Choose a base branch
from

Conversation

matthewmayer
Copy link
Contributor

ref #3169

This change will make it easier to handle ZIP codes where there are "holes" in the ranges.

For example Hawaii could use two ranges like this to exclude 96799 (American Samoa)

HI: [
    '{{number.int({"min": 96701,"max": 96798})}}',
    '{{number.int({"min": 96801,"max": 96898})}}',
  ],

Since faker.helpers.fake accepts an array, just need to change the type. Will change the actual definitions in a followup PR.

@matthewmayer matthewmayer requested a review from a team as a code owner October 11, 2024 01:22
Copy link

netlify bot commented Oct 11, 2024

Deploy Preview for fakerjs ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 877c511
🔍 Latest deploy log https://app.netlify.com/sites/fakerjs/deploys/67087dc6409fcd0008814ed5
😎 Deploy Preview https://deploy-preview-3170.fakerjs.dev
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

codecov bot commented Oct 11, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.97%. Comparing base (1403727) to head (877c511).
Report is 6 commits behind head on next.

Additional details and impacted files
@@            Coverage Diff            @@
##             next    #3170     +/-   ##
=========================================
  Coverage   99.96%   99.97%             
=========================================
  Files        2778     2797     +19     
  Lines      226364   227777   +1413     
  Branches      942      955     +13     
=========================================
+ Hits       226274   227709   +1435     
+ Misses         90       68     -22     
Files with missing lines Coverage Δ
src/definitions/location.ts 100.00% <ø> (ø)

... and 29 files with indirect coverage changes

@ST-DDT ST-DDT changed the title refactor(location): Allow postcode_by_state to take an array of patterns refactor(location): allow postcode_by_state to take an array of patterns Oct 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants