@@ -23,12 +23,12 @@ class GeoTrellisPathSpec extends AnyFunSpec {
2323
2424 it(" should fail to parse without a layer" ) {
2525 val path = GeoTrellisPath .parseOption(" file:///foo/bar?zoom=1" )
26- assert(path == None )
26+ assert(path.isEmpty )
2727 }
2828
2929 it(" should fail to parse without a zoom" ) {
3030 val path = GeoTrellisPath .parseOption(" file:///foo/bar?layer=baz" )
31- assert(path == None )
31+ assert(path.isEmpty )
3232 }
3333
3434 it(" should parse a local absolute file path without scheme" ) {
@@ -59,7 +59,7 @@ class GeoTrellisPathSpec extends AnyFunSpec {
5959 val path = GeoTrellisPath .parse(" file:///foo/bar?layer=baz&band_count=1&zoom=10" )
6060 assert(path.layerName == " baz" )
6161 assert(path.zoomLevel == 10 )
62- assert(path.bandCount == Some (1 ))
62+ assert(path.bandCount.contains (1 ))
6363 }
6464
6565 it(" should parse hdfs scheme" ) {
@@ -74,6 +74,20 @@ class GeoTrellisPathSpec extends AnyFunSpec {
7474 assert(path.layerName == " foo" )
7575 }
7676
77+ it(" should parse hbase scheme" ) {
78+ val path = GeoTrellisPath .parse(" hbase://zookeeper:2181?master=master_host&attributes=attributes_table&layers=layers_table&layer=foo&zoom=1" )
79+ assert(path.value == " hbase://zookeeper:2181?master=master_host&attributes=attributes_table&layers=layers_table" )
80+ assert(path.layerName == " foo" )
81+ assert(path.zoomLevel == 1 )
82+ }
83+
84+ it(" should parse accumulo scheme" ) {
85+ val path = GeoTrellisPath .parse(" accumulo://root:@localhost/fake?attributes=attributes&layers=tiles&layer=foo&zoom=1" )
86+ assert(path.value == " accumulo://root:@localhost/fake?attributes=attributes&layers=tiles" )
87+ assert(path.layerName == " foo" )
88+ assert(path.zoomLevel == 1 )
89+ }
90+
7791 it(" should parse absolute file scheme with gt+ prefix" ) {
7892 val path = GeoTrellisPath .parse(" gt+file:///absolute/path?layer=foo&zoom=1" )
7993 assert(path.value == " file:///absolute/path" )
0 commit comments