MCPcopy
hub / github.com/opentofu/opentofu / TestInternalProviders

Function TestInternalProviders

internal/command/plugins_test.go:38–53  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

36}
37
38func TestInternalProviders(t *testing.T) {
39 m := Meta{
40 WorkingDir: workdir.NewDir("."),
41 }
42 internal := m.internalProviders()
43 tfProvider, err := internal["terraform"]()
44 if err != nil {
45 t.Fatal(err)
46 }
47
48 schema := tfProvider.GetProviderSchema(t.Context())
49 _, found := schema.DataSources["terraform_remote_state"]
50 if !found {
51 t.Errorf("didn't find terraform_remote_state in internal \"terraform\" provider")
52 }
53}

Callers

nothing calls this directly

Calls 4

internalProvidersMethod · 0.95
NewDirFunction · 0.92
GetProviderSchemaMethod · 0.65
ContextMethod · 0.45

Tested by

no test coverage detected