@@ -48,7 +48,7 @@ func TestHttpGetter_header(t *testing.T) {
48
48
49
49
// Get it, which should error because it uses the file protocol.
50
50
err := g .Get (ctx , req )
51
- if ! strings .Contains (err .Error (), "download not supported for scheme " ) {
51
+ if ! strings .Contains (err .Error (), "no getter available for X-Terraform-Get source protocol " ) {
52
52
t .Fatalf ("unexpected error: %v" , err )
53
53
}
54
54
// But, using a wrapper client with a file getter will work.
@@ -127,7 +127,7 @@ func TestHttpGetter_meta(t *testing.T) {
127
127
128
128
// Get it, which should error because it uses the file protocol.
129
129
err := g .Get (ctx , req )
130
- if ! strings .Contains (err .Error (), "download not supported for scheme " ) {
130
+ if ! strings .Contains (err .Error (), "no getter available for X-Terraform-Get source protocol: " ) {
131
131
t .Fatalf ("unexpected error: %v" , err )
132
132
}
133
133
// But, using a wrapper client with a file getter will work.
@@ -427,7 +427,7 @@ func TestHttpGetter_auth(t *testing.T) {
427
427
428
428
// Get it, which should error because it uses the file protocol.
429
429
err := g .Get (ctx , req )
430
- if ! strings .Contains (err .Error (), "download not supported for scheme " ) {
430
+ if ! strings .Contains (err .Error (), "no getter available for X-Terraform-Get source protocol: " ) {
431
431
t .Fatalf ("unexpected error: %v" , err )
432
432
}
433
433
// But, using a wrapper client with a file getter will work.
@@ -477,7 +477,7 @@ func TestHttpGetter_authNetrc(t *testing.T) {
477
477
478
478
// Get it, which should error because it uses the file protocol.
479
479
err := g .Get (ctx , req )
480
- if ! strings .Contains (err .Error (), "download not supported for scheme " ) {
480
+ if ! strings .Contains (err .Error (), "no getter available for X-Terraform-Get source protocol: " ) {
481
481
t .Fatalf ("unexpected error: %v" , err )
482
482
}
483
483
// But, using a wrapper client with a file getter will work.
@@ -536,7 +536,7 @@ func TestHttpGetter_cleanhttp(t *testing.T) {
536
536
537
537
// Get it, which should error because it uses the file protocol.
538
538
err := g .Get (ctx , req )
539
- if ! strings .Contains (err .Error (), "download not supported for scheme " ) {
539
+ if ! strings .Contains (err .Error (), "no getter available for X-Terraform-Get source protocol: " ) {
540
540
t .Fatalf ("unexpected error: %v" , err )
541
541
}
542
542
// But, using a wrapper client with a file getter will work.
@@ -755,8 +755,8 @@ func TestHttpGetter__XTerraformGetConfiguredGettersBypass(t *testing.T) {
755
755
}
756
756
// We only care about the error messages that indicate that we can download the git header URL
757
757
if tt .errExpected && err != nil {
758
- if ! strings .Contains (err .Error (), "download not supported for scheme " ) {
759
- t .Fatalf ("expected download not supported for scheme , got: %v" , err )
758
+ if ! strings .Contains (err .Error (), "no getter available for X-Terraform-Get source protocol: " ) {
759
+ t .Fatalf ("expected no getter available for X-Terraform-Get source protocol: , got: %v" , err )
760
760
}
761
761
}
762
762
})
@@ -978,8 +978,8 @@ func TestHttpGetter_XTerraformWithClientFromContext(t *testing.T) {
978
978
}
979
979
980
980
if err != nil {
981
- if ! strings .Contains (err .Error (), "download not supported for scheme " ) {
982
- t .Fatalf ("expected download not supported for scheme , got: %v" , err )
981
+ if ! strings .Contains (err .Error (), "no getter available for X-Terraform-Get source protocol: " ) {
982
+ t .Fatalf ("expected no getter available for X-Terraform-Get source protocol: , got: %v" , err )
983
983
}
984
984
return
985
985
}
0 commit comments