-
-
Notifications
You must be signed in to change notification settings - Fork 852
/
dunn.json
93 lines (93 loc) · 2.7 KB
/
dunn.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": "55033",
"name": "Dunn County",
"state": "Wisconsin"
},
"country": "us",
"state": "wi",
"county": "Dunn"
},
"data": "http://216.222.161.54/ArcGIS/rest/services/DunnCounty/MapServer/20",
"type": "ESRI",
"conform": {
"type": "geojson",
"number": {
"function": "regexp",
"field": "ADDRESS",
"pattern": "^([EN]?\\d+)"
},
"street": {
"function": "regexp",
"field": "ADDRESS",
"pattern": "^(?:[EN]?\\d+(?:\\s*#(?:\\d))?)\\s+(.+)"
},
"unit": {
"function": "regexp",
"field": "ADDRESS",
"pattern": "#(\\d)"
}
},
"test": {
"enabled": true,
"description": "Dunn county house numbers can be prepended with a 'E' or 'N'",
"acceptance-tests": [
{
"description": "house with 'E' directional in number",
"inputs": {
"ADDRESS": "E02064 1070TH AV"
},
"expected": {
"number": "E02064",
"street": "1070TH AV",
"unit": ""
}
},
{
"description": "house with 'N' directional in number",
"inputs": {
"ADDRESS": "N09596 640TH ST"
},
"expected": {
"number": "N09596",
"street": "640TH ST",
"unit": ""
}
},
{
"description": "plain numbers-only house number",
"inputs": {
"ADDRESS": "120 MAIN ST"
},
"expected": {
"number": "120",
"street": "MAIN ST",
"unit": ""
}
},
{
"description": "address with unit, no space",
"inputs": {
"ADDRESS": "1120#2 N BROADWAY ST"
},
"expected": {
"number": "1120",
"street": "N BROADWAY ST",
"unit": "2"
}
},
{
"description": "address with unit, with space",
"inputs": {
"ADDRESS": "393 #2 RED CEDAR ST NE"
},
"expected": {
"number": "393",
"street": "RED CEDAR ST NE",
"unit": "2"
}
}
]
}
}