diff options
| author | Michael Hoffmann <mhoffm@posteo.de> | 2022-04-24 23:16:35 +0200 |
|---|---|---|
| committer | Stephan Seitz <stephan.seitz@fau.de> | 2022-04-25 23:36:36 +0200 |
| commit | 82e43748cf70adab261ba0a23a342774bd5b9088 (patch) | |
| tree | c86943a612b0ab45801f7a3845310157e1778874 /tests | |
| parent | indents(hcl): fix indentation queries (diff) | |
| download | nvim-treesitter-82e43748cf70adab261ba0a23a342774bd5b9088.tar nvim-treesitter-82e43748cf70adab261ba0a23a342774bd5b9088.tar.gz nvim-treesitter-82e43748cf70adab261ba0a23a342774bd5b9088.tar.bz2 nvim-treesitter-82e43748cf70adab261ba0a23a342774bd5b9088.tar.lz nvim-treesitter-82e43748cf70adab261ba0a23a342774bd5b9088.tar.xz nvim-treesitter-82e43748cf70adab261ba0a23a342774bd5b9088.tar.zst nvim-treesitter-82e43748cf70adab261ba0a23a342774bd5b9088.zip | |
indent(hcl): fix function calls
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/indent/hcl/function_call.tf | 6 | ||||
| -rw-r--r-- | tests/indent/hcl_spec.lua | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/tests/indent/hcl/function_call.tf b/tests/indent/hcl/function_call.tf new file mode 100644 index 000000000..44c477e48 --- /dev/null +++ b/tests/indent/hcl/function_call.tf @@ -0,0 +1,6 @@ +test { + x = f( + a, + b, + ) +} diff --git a/tests/indent/hcl_spec.lua b/tests/indent/hcl_spec.lua index b97af2786..ee53d89fc 100644 --- a/tests/indent/hcl_spec.lua +++ b/tests/indent/hcl_spec.lua @@ -29,5 +29,7 @@ describe("indent HCL:", function() run:new_line("multiple-attributes.tf", { on_line = 4, text = "a = 1", indent = 0 }) run:new_line("nested_blocks.tf", { on_line = 3, text = "a = 1", indent = 4 }) run:new_line("nested_blocks.tf", { on_line = 4, text = "a = 1", indent = 2 }) + run:new_line("function_call.tf", { on_line = 4, text = "c,", indent = 4 }) + run:new_line("function_call.tf", { on_line = 5, text = "a = 1", indent = 2 }) end) end) |
