Skip to content

Commit 069cad7

Browse files
authored
Remove deprecated IncludeNotCreated option (#274)
1 parent ee6dcd7 commit 069cad7

File tree

6 files changed

+332
-356
lines changed

6 files changed

+332
-356
lines changed

plugin/internal/fromproto/fromproto.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -267,10 +267,9 @@ func GetModuleContentOption(opts *proto.GetModuleContent_Option) tflint.GetModul
267267
}
268268

269269
return tflint.GetModuleContentOption{
270-
ModuleCtx: ModuleCtxType(opts.ModuleCtx),
271-
IncludeNotCreated: opts.IncludeNotCreated,
272-
ExpandMode: ExpandMode(opts.ExpandMode),
273-
Hint: GetModuleContentHint(opts.Hint),
270+
ModuleCtx: ModuleCtxType(opts.ModuleCtx),
271+
ExpandMode: ExpandMode(opts.ExpandMode),
272+
Hint: GetModuleContentHint(opts.Hint),
274273
}
275274
}
276275

plugin/internal/plugin2host/plugin2host_test.go

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -651,10 +651,9 @@ volume_size = 10`)
651651
Name: "get content with options",
652652
Args: func() (*hclext.BodySchema, *tflint.GetModuleContentOption) {
653653
return &hclext.BodySchema{}, &tflint.GetModuleContentOption{
654-
ModuleCtx: tflint.RootModuleCtxType,
655-
IncludeNotCreated: true,
656-
ExpandMode: tflint.ExpandModeNone,
657-
Hint: tflint.GetModuleContentHint{ResourceType: "aws_instance"},
654+
ModuleCtx: tflint.RootModuleCtxType,
655+
ExpandMode: tflint.ExpandModeNone,
656+
Hint: tflint.GetModuleContentHint{ResourceType: "aws_instance"},
658657
}
659658
},
660659
ServerImpl: func(schema *hclext.BodySchema, opts tflint.GetModuleContentOption) (*hclext.BodyContent, hcl.Diagnostics) {
@@ -663,11 +662,6 @@ volume_size = 10`)
663662
&hcl.Diagnostic{Severity: hcl.DiagError, Summary: "unexpected moduleCtx options"},
664663
}
665664
}
666-
if !opts.IncludeNotCreated {
667-
return &hclext.BodyContent{}, hcl.Diagnostics{
668-
&hcl.Diagnostic{Severity: hcl.DiagError, Summary: "unexpected includeNotCreatedResources options"},
669-
}
670-
}
671665
if opts.ExpandMode != tflint.ExpandModeNone {
672666
return &hclext.BodyContent{}, hcl.Diagnostics{
673667
&hcl.Diagnostic{Severity: hcl.DiagError, Summary: "unexpected expand mode options"},

0 commit comments

Comments
 (0)