aboutsummaryrefslogtreecommitdiffstats
path: root/tests/indent/dart_spec.lua
diff options
context:
space:
mode:
authorSzeLamC <chanszelam7725@gmail.com>2023-02-25 05:06:31 +0800
committerGitHub <noreply@github.com>2023-02-24 16:06:31 -0500
commit68ab44277cd3eca7c5f1d227f153bd4e56d6303f (patch)
tree1ab996b944a5a3396ff75ed860c5ea5b0c88f232 /tests/indent/dart_spec.lua
parentfeat(solidity): use maintained parser and update highlights accordingly (diff)
downloadnvim-treesitter-68ab44277cd3eca7c5f1d227f153bd4e56d6303f.tar
nvim-treesitter-68ab44277cd3eca7c5f1d227f153bd4e56d6303f.tar.gz
nvim-treesitter-68ab44277cd3eca7c5f1d227f153bd4e56d6303f.tar.bz2
nvim-treesitter-68ab44277cd3eca7c5f1d227f153bd4e56d6303f.tar.lz
nvim-treesitter-68ab44277cd3eca7c5f1d227f153bd4e56d6303f.tar.xz
nvim-treesitter-68ab44277cd3eca7c5f1d227f153bd4e56d6303f.tar.zst
nvim-treesitter-68ab44277cd3eca7c5f1d227f153bd4e56d6303f.zip
fix(dart): add `@indent_end` to } (#4167)
* fix dart indentation after } * add some simple test case
Diffstat (limited to 'tests/indent/dart_spec.lua')
-rw-r--r--tests/indent/dart_spec.lua20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/indent/dart_spec.lua b/tests/indent/dart_spec.lua
new file mode 100644
index 000000000..8b05cc753
--- /dev/null
+++ b/tests/indent/dart_spec.lua
@@ -0,0 +1,20 @@
+local Runner = require("tests.indent.common").Runner
+
+local run = Runner:new(it, "tests/indent/dart", {
+ tabstop = 4,
+ shiftwidth = 2,
+ softtabstop = 0,
+ expandtab = true,
+})
+
+describe("indent Lua:", function()
+ describe("whole file:", function()
+ run:whole_file(".", {
+ expected_failures = {},
+ })
+ end)
+end)
+
+describe("new line:", function()
+ run:new_line("class.dart", { on_line = 2, text = "var x;", indent = 0 })
+end)