-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add en_CA instances, StringRegexPart (#18)
* Add en_CA instances, StringRegexPart * typo * en_CA ResourceLoader * Update resource loading * StringRegexPart coverage * Add test coverage across locales * Add other case * add codecov threshold * at least 100 for tests
- Loading branch information
1 parent
53a4d7c
commit 5e59208
Showing
15 changed files
with
523 additions
and
403 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
coverage: | ||
status: | ||
project: | ||
default: | ||
threshold: 5% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
include "en_CA/address.conf" | ||
include "en_CA/internet.conf" | ||
include "en_CA/phone.conf" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
address { | ||
postal-code-builder = {options = [{parts = [{type = "string-regex-part", value = "[A-CEJ-NPR-TVXY][0-9][A-CEJ-NPR-TV-Z] ?[0-9][A-CEJ-NPR-TV-Z][0-9]"}]}]} | ||
provinces = ["AB", "BC", "MB", "NB", "NL", "NS", "NU", "NT", "ON", "PE", "QC", "SK", "YT"] | ||
full-address-builder = { | ||
options = [ | ||
{parts = [ | ||
{type = "string-builder-part", value = ${address.street-address-builder}, suffix = ", "}, | ||
{type = "string-builder-part", value = ${address.city-builder}, suffix = ", "}, | ||
{type = "seq-string-part", value = ${address.provinces}, suffix = " "}, | ||
{type = "string-builder-part", value = ${address.postal-code-builder}} | ||
]}, | ||
{parts = [ | ||
{type = "string-builder-part", value = ${address.street-address-builder}, suffix = " "}, | ||
{type = "seq-string-part", value = ${address.secondary-addresses}, suffix = ", "}, | ||
{type = "string-builder-part", value = ${address.city-builder}, suffix = ", "}, | ||
{type = "seq-string-part", value = ${address.provinces}, suffix = " "}, | ||
{type = "string-builder-part", value = ${address.postal-code-builder}} | ||
]} | ||
] | ||
} | ||
default-country = {code = "CA", name = "Canada"} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
internet { | ||
free-email-domains = [gmail.com, yahoo.ca, hotmail.com] | ||
domain-suffixes = [ca, com, biz, info, name, net, org] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
phone { | ||
area-codes = ["204", "226", "236", "249", "250", "289", "306", "343", "365", "403", "416", "418", "431", "437", "438", "450", "506", "514", "519", "579", "581", "587", "604", "613", "639", "647", "705", "709", "778", "780", "807", "819", "867", "873", "902", "905"] | ||
exchange-codes = ["201", "202", "203", "205", "206", "207", "208", "209", "210", "212", "213", "214", "215", "216", "217", "218", "219", "224", "225", "227", "228", "229", "231", "234", "239", "240", "248", "251", "252", "253", "254", "256", "260", "262", "267", "269", "270", "276", "281", "283", "301", "302", "303", "304", "305", "307", "308", "309", "310", "312", "313", "314", "315", "316", "317", "318", "319", "320", "321", "323", "330", "331", "334", "336", "337", "339", "347", "351", "352", "360", "361", "386", "401", "402", "404", "405", "406", "407", "408", "409", "410", "412", "413", "414", "415", "417", "419", "423", "424", "425", "434", "435", "440", "443", "445", "464", "469", "470", "475", "478", "479", "480", "484", "501", "502", "503", "504", "505", "507", "508", "509", "510", "512", "513", "515", "516", "517", "518", "520", "530", "540", "541", "551", "557", "559", "561", "562", "563", "564", "567", "570", "571", "573", "574", "580", "585", "586", "601", "602", "603", "605", "606", "607", "608", "609", "610", "612", "614", "615", "616", "617", "618", "619", "620", "623", "626", "630", "631", "636", "641", "646", "650", "651", "660", "661", "662", "667", "678", "682", "701", "702", "703", "704", "706", "707", "708", "712", "713", "714", "715", "716", "717", "718", "719", "720", "724", "727", "731", "732", "734", "737", "740", "754", "757", "760", "763", "765", "770", "772", "773", "774", "775", "781", "785", "786", "801", "802", "803", "804", "805", "806", "808", "810", "812", "813", "814", "815", "816", "817", "818", "828", "830", "831", "832", "835", "843", "845", "847", "848", "850", "856", "857", "858", "859", "860", "862", "863", "864", "865", "870", "872", "878", "901", "903", "904", "906", "907", "908", "909", "910", "912", "913", "914", "915", "916", "917", "918", "919", "920", "925", "928", "931", "936", "937", "940", "941", "947", "949", "952", "954", "956", "959", "970", "971", "972", "973", "975", "978", "979", "980", "984", "985", "989"] | ||
subscriber-number = "####" | ||
extension = ${phone.subscriber-number} | ||
phone-number-builder = { | ||
options = [ | ||
{parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}}], weight = 2}, | ||
{prefix = "(", parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = ")-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}}], weight = 2}, | ||
{prefix = "1-", parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}}], weight = 2}, | ||
{parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "."}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "."}, {type = "string-part", value = ${phone.subscriber-number}}], weight = 2}, | ||
{parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}, suffix = " "}, {prefix = "x", type = "string-part", value = ${phone.extension}}], weight = 3}, | ||
{prefix = "(", parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = ")-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}, suffix = " "}, {prefix = "x", type = "string-part", value = ${phone.extension}}], weight = 3}, | ||
{prefix = "1-", parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}, suffix = " "}, {prefix = "x", type = "string-part", value = ${phone.extension}}], weight = 3}, | ||
{parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "."}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "."}, {type = "string-part", value = ${phone.subscriber-number}, suffix = " "}, {prefix = "x", type = "string-part", value = ${phone.extension}}], weight = 3}, | ||
] | ||
} | ||
cell-number-builder = { | ||
options = [ | ||
{parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}}]}, | ||
{prefix = "(", parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = ")-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}}]}, | ||
{prefix = "1-", parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "-"}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "-"}, {type = "string-part", value = ${phone.subscriber-number}}]}, | ||
{parts = [{type = "seq-string-part", value = ${phone.area-codes}, suffix = "."}, {type = "seq-string-part", value = ${phone.exchange-codes}, suffix = "."}, {type = "string-part", value = ${phone.subscriber-number}}]}, | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.