Versions in this module Expand all Collapse all v0 v0.0.1 Aug 28, 2024 Changes in this version + const ApplyTestCommand + const DefaultTestDirectory + const NormalTestMode + const PlanTestCommand + const RefreshOnlyTestMode + var ResourceBlockSchema = &hcl.BodySchema + func IsEmptyDir(path string) (bool, error) + func IsIgnoredFile(name string) bool + func MergeBodies(base, override hcl.Body) hcl.Body + func ParseProviderConfigCompact(traversal hcl.Traversal) (addrs.LocalProviderConfig, tfdiags.Diagnostics) + func ParseProviderConfigCompactStr(str string) (addrs.LocalProviderConfig, tfdiags.Diagnostics) + func SynthBody(filename string, values map[string]cty.Value) hcl.Body + type Backend struct + Config hcl.Body + DeclRange hcl.Range + Eval *StaticEvaluator + Type string + TypeRange hcl.Range + func (b *Backend) Decode(schema *configschema.Block) (cty.Value, hcl.Diagnostics) + func (b *Backend) Hash(schema *configschema.Block) (int, hcl.Diagnostics) + type Check struct + Asserts []*CheckRule + DataResource *Resource + DeclRange hcl.Range + Name string + func (c Check) Accessible(addr addrs.Referenceable) bool + func (c Check) Addr() addrs.Check + type CheckRule struct + Condition hcl.Expression + DeclRange hcl.Range + ErrorMessage hcl.Expression + type CloudConfig struct + Config hcl.Body + DeclRange hcl.Range + func (c *CloudConfig) ToBackendConfig() Backend + type Config struct + CallRange hcl.Range + Children map[string]*Config + Module *Module + Parent *Config + Path addrs.Module + Root *Config + SourceAddr addrs.ModuleSource + SourceAddrRange hcl.Range + SourceAddrRaw string + Version *version.Version + func BuildConfig(root *Module, walker ModuleWalker) (*Config, hcl.Diagnostics) + func NewEmptyConfig() *Config + func (c *Config) AllModules() []*Config + func (c *Config) CheckCoreVersionRequirements() hcl.Diagnostics + func (c *Config) DeepEach(cb func(c *Config)) + func (c *Config) Depth() int + func (c *Config) Descendent(path addrs.Module) *Config + func (c *Config) DescendentForInstance(path addrs.ModuleInstance) *Config + func (c *Config) EntersNewPackage() bool + func (c *Config) ProviderForConfigAddr(addr addrs.LocalProviderConfig) addrs.Provider + func (c *Config) ProviderRequirements() (getproviders.Requirements, hcl.Diagnostics) + func (c *Config) ProviderRequirementsByModule() (*ModuleRequirements, hcl.Diagnostics) + func (c *Config) ProviderRequirementsShallow() (getproviders.Requirements, hcl.Diagnostics) + func (c *Config) ProviderTypes() []addrs.Provider + func (c *Config) ResolveAbsProviderAddr(addr addrs.ProviderConfig, inModule addrs.Module) addrs.AbsProviderConfig + func (c *Config) TransformForTest(run *TestRun, file *TestFile) (func(), hcl.Diagnostics) + func (c *Config) VerifyDependencySelections(depLocks *depsfile.Locks) []error + type Connection struct + Config hcl.Body + DeclRange hcl.Range + type Container interface + Accessible func(addr addrs.Referenceable) bool + type File struct + ActiveExperiments experiments.Set + Backends []*Backend + Checks []*Check + CloudConfigs []*CloudConfig + CoreVersionConstraints []VersionConstraint + DataResources []*Resource + Encryptions []*config.EncryptionConfig + Import []*Import + Locals []*Local + ManagedResources []*Resource + ModuleCalls []*ModuleCall + Moved []*Moved + Outputs []*Output + ProviderConfigs []*Provider + ProviderMetas []*ProviderMeta + Removed []*Removed + RequiredProviders []*RequiredProviders + Variables []*Variable + type Import struct + DeclRange hcl.Range + ForEach hcl.Expression + ID hcl.Expression + Provider addrs.Provider + ProviderConfigRef *ProviderConfigRef + ProviderDeclRange hcl.Range + ResolvedTo *addrs.AbsResourceInstance + StaticTo addrs.ConfigResource + To hcl.Expression + type Local struct + DeclRange hcl.Range + Expr hcl.Expression + Name string + func (l *Local) Addr() addrs.LocalValue + type ManagedResource struct + Connection *Connection + CreateBeforeDestroy bool + CreateBeforeDestroySet bool + IgnoreAllChanges bool + IgnoreChanges []hcl.Traversal + PreventDestroy bool + PreventDestroySet bool + Provisioners []*Provisioner + type MockProvider struct + Alias string + AliasRange *hcl.Range + DeclRange hcl.Range + MockResources []*MockResource + Name string + NameRange hcl.Range + type MockResource struct + Defaults map[string]cty.Value + Mode addrs.ResourceMode + Type string + type Module struct + ActiveExperiments experiments.Set + Backend *Backend + Checks map[string]*Check + CloudConfig *CloudConfig + CoreVersionConstraints []VersionConstraint + DataResources map[string]*Resource + Encryption *config.EncryptionConfig + Import []*Import + IsOverridden bool + Locals map[string]*Local + ManagedResources map[string]*Resource + ModuleCalls map[string]*ModuleCall + Moved []*Moved + Outputs map[string]*Output + ProviderConfigs map[string]*Provider + ProviderLocalNames map[addrs.Provider]string + ProviderMetas map[addrs.Provider]*ProviderMeta + ProviderRequirements *RequiredProviders + Removed []*Removed + SourceDir string + StaticEvaluator *StaticEvaluator + Tests map[string]*TestFile + Variables map[string]*Variable + func NewModule(primaryFiles, overrideFiles []*File, call StaticModuleCall, sourceDir string, ...) (*Module, hcl.Diagnostics) + func NewModuleWithTests(primaryFiles, overrideFiles []*File, testFiles map[string]*TestFile, ...) (*Module, hcl.Diagnostics) + func (m *Module) CheckCoreVersionRequirements(path addrs.Module, sourceAddr addrs.ModuleSource) hcl.Diagnostics + func (m *Module) GetProviderConfig(name, alias string) (*Provider, bool) + func (m *Module) ImpliedProviderForUnqualifiedType(pType string) addrs.Provider + func (m *Module) LocalNameForProvider(p addrs.Provider) string + func (m *Module) ProviderForLocalConfig(pc addrs.LocalProviderConfig) addrs.Provider + func (m *Module) ResourceByAddr(addr addrs.Resource) *Resource + type ModuleCall struct + Config hcl.Body + Count hcl.Expression + DeclRange hcl.Range + DependsOn []hcl.Traversal + ForEach hcl.Expression + Name string + Providers []PassedProviderConfig + Source hcl.Expression + SourceAddr addrs.ModuleSource + SourceAddrRaw string + SourceSet bool + Variables StaticModuleVariables + Version VersionConstraint + VersionAttr *hcl.Attribute + Workspace string + func (mc *ModuleCall) EntersNewPackage() bool + type ModuleRequest struct + Call StaticModuleCall + CallRange hcl.Range + Name string + Parent *Config + Path addrs.Module + SourceAddr addrs.ModuleSource + SourceAddrRange hcl.Range + VersionConstraint VersionConstraint + type ModuleRequirements struct + Children map[string]*ModuleRequirements + Name string + Requirements getproviders.Requirements + SourceAddr addrs.ModuleSource + SourceDir string + Tests map[string]*TestFileModuleRequirements + type ModuleWalker interface + LoadModule func(req *ModuleRequest) (*Module, *version.Version, hcl.Diagnostics) + var DisabledModuleWalker ModuleWalker + type ModuleWalkerFunc func(req *ModuleRequest) (*Module, *version.Version, hcl.Diagnostics) + func (f ModuleWalkerFunc) LoadModule(req *ModuleRequest) (*Module, *version.Version, hcl.Diagnostics) + type Moved struct + DeclRange hcl.Range + From *addrs.MoveEndpoint + To *addrs.MoveEndpoint + type Output struct + DeclRange hcl.Range + DependsOn []hcl.Traversal + Description string + DescriptionSet bool + Expr hcl.Expression + IsOverridden bool + Name string + OverrideValue *cty.Value + Preconditions []*CheckRule + Sensitive bool + SensitiveSet bool + func (o *Output) Addr() addrs.OutputValue + type OverrideModule struct + Outputs map[string]cty.Value + Target hcl.Traversal + TargetParsed addrs.Module + type OverrideResource struct + Mode addrs.ResourceMode + Target hcl.Traversal + TargetParsed *addrs.ConfigResource + Values map[string]cty.Value + type Parser struct + func NewParser(fs afero.Fs) *Parser + func (p *Parser) AllowLanguageExperiments(allowed bool) + func (p *Parser) ForceFileSource(filename string, src []byte) + func (p *Parser) IsConfigDir(path string) bool + func (p *Parser) LoadConfigDir(path string, call StaticModuleCall) (*Module, hcl.Diagnostics) + func (p *Parser) LoadConfigDirSelective(path string, call StaticModuleCall, load SelectiveLoader) (*Module, hcl.Diagnostics) + func (p *Parser) LoadConfigDirWithTests(path string, testDirectory string, call StaticModuleCall) (*Module, hcl.Diagnostics) + func (p *Parser) LoadConfigFile(path string) (*File, hcl.Diagnostics) + func (p *Parser) LoadConfigFileOverride(path string) (*File, hcl.Diagnostics) + func (p *Parser) LoadHCLFile(path string) (hcl.Body, hcl.Diagnostics) + func (p *Parser) LoadTestFile(path string) (*TestFile, hcl.Diagnostics) + func (p *Parser) Sources() map[string]*hcl.File + func (p Parser) ConfigDirFiles(dir string) (primary, override []string, diags hcl.Diagnostics) + func (p Parser) ConfigDirFilesWithTests(dir string, testDirectory string) (primary, override, tests []string, diags hcl.Diagnostics) + type PassedProviderConfig struct + InChild *ProviderConfigRef + InParent *ProviderConfigRef + type Provider struct + Alias string + AliasRange *hcl.Range + Config hcl.Body + DeclRange hcl.Range + IsMocked bool + MockResources []*MockResource + Name string + NameRange hcl.Range + Version VersionConstraint + func (p *Provider) Addr() addrs.LocalProviderConfig + type ProviderConfigRef struct + Alias string + AliasRange *hcl.Range + Name string + NameRange hcl.Range + func (r *ProviderConfigRef) Addr() addrs.LocalProviderConfig + func (r *ProviderConfigRef) String() string + type ProviderMeta struct + Config hcl.Body + DeclRange hcl.Range + Provider string + ProviderRange hcl.Range + type Provisioner struct + Config hcl.Body + Connection *Connection + DeclRange hcl.Range + OnFailure ProvisionerOnFailure + Type string + TypeRange hcl.Range + When ProvisionerWhen + type ProvisionerOnFailure int + const ProvisionerOnFailureContinue + const ProvisionerOnFailureFail + const ProvisionerOnFailureInvalid + func (i ProvisionerOnFailure) String() string + type ProvisionerWhen int + const ProvisionerWhenCreate + const ProvisionerWhenDestroy + const ProvisionerWhenInvalid + func (i ProvisionerWhen) String() string + type Removed struct + DeclRange hcl.Range + From *addrs.RemoveEndpoint + type RequiredProvider struct + Aliases []addrs.LocalProviderConfig + DeclRange hcl.Range + Name string + Requirement VersionConstraint + Source string + Type addrs.Provider + type RequiredProviders struct + DeclRange hcl.Range + RequiredProviders map[string]*RequiredProvider + type Resource struct + Config hcl.Body + Container Container + Count hcl.Expression + DeclRange hcl.Range + DependsOn []hcl.Traversal + ForEach hcl.Expression + IsOverridden bool + Managed *ManagedResource + Mode addrs.ResourceMode + Name string + OverrideValues map[string]cty.Value + Postconditions []*CheckRule + Preconditions []*CheckRule + Provider addrs.Provider + ProviderConfigRef *ProviderConfigRef + TriggersReplacement []hcl.Expression + Type string + TypeRange hcl.Range + func (r *Resource) Addr() addrs.Resource + func (r *Resource) HasCustomConditions() bool + func (r *Resource) ProviderConfigAddr() addrs.LocalProviderConfig + type SelectiveLoader int + const SelectiveLoadAll + const SelectiveLoadBackend + const SelectiveLoadEncryption + type StateEncryption struct + Config hcl.Body + DeclRange hcl.Range + Type string + TypeRange hcl.Range + type StaticEvaluator struct + func NewStaticEvaluator(mod *Module, call StaticModuleCall) *StaticEvaluator + func (s StaticEvaluator) DecodeBlock(body hcl.Body, spec hcldec.Spec, ident StaticIdentifier) (cty.Value, hcl.Diagnostics) + func (s StaticEvaluator) DecodeExpression(expr hcl.Expression, ident StaticIdentifier, val any) hcl.Diagnostics + func (s StaticEvaluator) EvalContext(ident StaticIdentifier, refs []*addrs.Reference) (*hcl.EvalContext, hcl.Diagnostics) + func (s StaticEvaluator) EvalContextWithParent(parent *hcl.EvalContext, ident StaticIdentifier, refs []*addrs.Reference) (*hcl.EvalContext, hcl.Diagnostics) + func (s StaticEvaluator) Evaluate(expr hcl.Expression, ident StaticIdentifier) (cty.Value, hcl.Diagnostics) + type StaticIdentifier struct + DeclRange hcl.Range + Module addrs.Module + Subject string + func (ref StaticIdentifier) String() string + type StaticModuleCall struct + func NewStaticModuleCall(addr addrs.Module, vars StaticModuleVariables, rootPath string, ...) StaticModuleCall + func RootModuleCallForTesting() StaticModuleCall + func (s StaticModuleCall) WithVariables(vars StaticModuleVariables) StaticModuleCall + type StaticModuleVariables func(v *Variable) (cty.Value, hcl.Diagnostics) + type TestCommand rune + type TestFile struct + MockProviders map[string]*MockProvider + OverrideModules []*OverrideModule + OverrideResources []*OverrideResource + Providers map[string]*Provider + Runs []*TestRun + Variables map[string]hcl.Expression + VariablesDeclRange hcl.Range + func (file *TestFile) Validate() tfdiags.Diagnostics + type TestFileModuleRequirements struct + Requirements getproviders.Requirements + Runs map[string]*ModuleRequirements + type TestMode rune + type TestRun struct + CheckRules []*CheckRule + Command TestCommand + ConfigUnderTest *Config + DeclRange hcl.Range + ExpectFailures []hcl.Traversal + Module *TestRunModuleCall + Name string + NameDeclRange hcl.Range + Options *TestRunOptions + OverrideModules []*OverrideModule + OverrideResources []*OverrideResource + Providers []PassedProviderConfig + Variables map[string]hcl.Expression + VariablesDeclRange hcl.Range + func (run *TestRun) Validate() tfdiags.Diagnostics + type TestRunModuleCall struct + DeclRange hcl.Range + Source addrs.ModuleSource + SourceDeclRange hcl.Range + Version VersionConstraint + type TestRunOptions struct + DeclRange hcl.Range + Mode TestMode + Refresh bool + Replace []hcl.Traversal + Target []hcl.Traversal + type Variable struct + ConstraintType cty.Type + DeclRange hcl.Range + Default cty.Value + Description string + DescriptionSet bool + Name string + Nullable bool + NullableSet bool + ParsingMode VariableParsingMode + Sensitive bool + SensitiveSet bool + Type cty.Type + TypeDefaults *typeexpr.Defaults + Validations []*CheckRule + func (v *Variable) Addr() addrs.InputVariable + func (v *Variable) Required() bool + type VariableParsingMode rune + const VariableParseHCL + const VariableParseLiteral + func (m VariableParsingMode) Parse(name, value string) (cty.Value, hcl.Diagnostics) + type VariableTypeHint rune + const TypeHintList + const TypeHintMap + const TypeHintNone + const TypeHintString + func (i VariableTypeHint) String() string + type VersionConstraint struct + DeclRange hcl.Range + Required version.Constraints