github.com/vtorhonen/terraform@v0.9.0-beta2.0.20170307220345-5d894e4ffda7/builtin/providers/aws/hosted_zones_test.go (about) 1 package aws 2 3 import ( 4 "testing" 5 ) 6 7 func TestHostedZoneIDForRegion(t *testing.T) { 8 if r := HostedZoneIDForRegion("us-east-1"); r != "Z3AQBSTGFYJSTF" { 9 t.Fatalf("bad: %s", r) 10 } 11 if r := HostedZoneIDForRegion("ap-southeast-2"); r != "Z1WCIGYICN2BYD" { 12 t.Fatalf("bad: %s", r) 13 } 14 15 // Bad input should be empty string 16 if r := HostedZoneIDForRegion("not-a-region"); r != "" { 17 t.Fatalf("bad: %s", r) 18 } 19 }