def test_cbsa_finder_twohits():
s3_conn = boto.connect_s3()
s3_conn.create_bucket('geobucket')
shapefile_name = 'tests/sample_cbsa_shapefile.shp'
finder = S3CachedCBSAFinder(
s3_conn=s3_conn,
cache_s3_path='geobucket/cbsas.json',
shapefile_name=shapefile_name
)
sample_input = {
"bbox": {
"northeast": [38.00, -81.05],
"southwest": [35.13, -88.18]
},
}
assert finder.query(sample_input) == (
'40080',
'Richmond-Berea, KY Micro Area',
)
test_geocoders.py 文件源码
python
阅读 22
收藏 0
点赞 0
评论 0
评论列表
文章目录