X-Git-Url: https://git.madduck.net/etc/vim.git/blobdiff_plain/5e955165c22ec1bb874728195a7ce2a48b2edbac..5f4184fb1200b329e810c1e4c866c86fdf44c135:/spec/indent/indent_spec.rb?ds=sidebyside diff --git a/spec/indent/indent_spec.rb b/spec/indent/indent_spec.rb index b08203b..6e5a79f 100644 --- a/spec/indent/indent_spec.rb +++ b/spec/indent/indent_spec.rb @@ -651,3 +651,18 @@ describe "Handles far away opening curly brackets" do indent.should == shiftwidth end end + +describe "Compact multiline dict" do + before { vim.feedkeys '\ggdGid = {"one": 1,' } + + it "gets indented correctly" do + vim.feedkeys '\' + proposed_indent.should == 5 + + vim.feedkeys '"two": 2}' + proposed_indent.should == 5 + + vim.feedkeys '\' + proposed_indent.should == 0 + end +end