/
lincoln.json
93 lines (93 loc) · 2.72 KB
/
lincoln.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
{
"coverage": {
"US Census": {
"geoid": "35027",
"name": "Lincoln",
"state": "New Mexico"
},
"country": "us",
"state": "nm",
"county": "Lincoln"
},
"data": "https://services.arcgis.com/4YineAQdtmx0tv46/ArcGIS/rest/services/LincolnNMFeatures/FeatureServer/0",
"protocol": "ESRI",
"conform": {
"format": "geojson",
"number": {
"function": "regexp",
"field": "FULLADDR",
"pattern": "(\\d+)[A-Z]?$"
},
"street": {
"function": "regexp",
"field": "FULLADDR",
"pattern": "^(.+?)\\b(?:\\s*(?:-|=|\\.)\\s*)(?:\\d+[A-Z]?)?$"
},
"unit": {
"function": "regexp",
"field": "FULLADDR",
"pattern": "\\d+([A-Z])$"
}
},
"test": {
"enabled": true,
"description": "these are the tests that exercise number-suffixed addresses",
"acceptance-tests": [
{
"description": "= delimiter, alphanumeric number",
"inputs": {
"FULLADDR": "SAN MIGUEL RD=114A"
},
"expected": {
"number": "114",
"street": "SAN MIGUEL RD",
"unit": "A"
}
},
{
"description": "= delimiter with padding",
"inputs": {
"FULLADDR": "LAGUNA VISTA PL = 102"
},
"expected": {
"number": "102",
"street": "LAGUNA VISTA PL",
"unit": ""
}
},
{
"description": "street ends with number",
"inputs": {
"FULLADDR": "US HWY 54-11457"
},
"expected": {
"number": "11457",
"street": "US HWY 54",
"unit": ""
}
},
{
"description": ". delimiter",
"inputs": {
"FULLADDR": "N. CENTRAL DR.310"
},
"expected": {
"number": "310",
"street": "N. CENTRAL DR",
"unit": ""
}
},
{
"description": "0-length delimiter, doesn't currently work",
"inputs": {
"FULLADDR": "HULL RD0405"
},
"expected": {
"number": "0405",
"street": "",
"unit": ""
}
}
]
}
}