terraform-synthesizer 0.0.16 → 0.0.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/terraform-synthesizer/version.rb +1 -1
- data/lib/terraform-synthesizer.rb +5 -4
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dfa8a6f04f030c12789a17bed2daa44cb64ca012f96321631f325cd5b0af27b5
|
4
|
+
data.tar.gz: 41d44dfcb45b9ba54223d2ff817eb48401e6db4902b938a90f3d7cd7a9d7363b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d2f7a2dd85260ed9f22502de55079ecb4fdbc8f628b9912e78442fad8a39f6f7c2f69fd7290bf5ddff8fdeec7583c3263ed11ad9b90670e2e95f43e04eaaa61f
|
7
|
+
data.tar.gz: 544b05947a1118635e649d0536b7ff0e8b925c824f74962f8c58beb5cf622999923a27e6649e61d85e4da26bfe8eb908106ed8e8871c6598c1d03dc3b952bcb2
|
@@ -29,7 +29,10 @@ class TerraformSynthesizer < AbstractSynthesizer
|
|
29
29
|
def method_missing(method_name, *args, &)
|
30
30
|
BLOCK_KEYS.each do |block_key|
|
31
31
|
if @in_block_key
|
32
|
-
|
32
|
+
if args[0].nil? || args[0].empty?
|
33
|
+
raise ArgumentError,
|
34
|
+
%(not assigning anything to this #{block_key})
|
35
|
+
end
|
33
36
|
|
34
37
|
@in_block_key = false
|
35
38
|
@translation[:template][block_key.to_sym][method_name.to_sym] = args[0]
|
@@ -38,10 +41,8 @@ class TerraformSynthesizer < AbstractSynthesizer
|
|
38
41
|
|
39
42
|
@translation = {} if @translation.nil?
|
40
43
|
@translation[:template] = {} if @translation[:template].nil?
|
44
|
+
@translation[:template][block_key.to_sym] = {} \
|
41
45
|
if @translation[:template][block_key.to_sym].nil?
|
42
|
-
@translation[:template][block_key.to_sym] =
|
43
|
-
{}
|
44
|
-
end
|
45
46
|
@in_block_key = true
|
46
47
|
|
47
48
|
yield
|