From fa5d1baea955d674acf869ebac2485d4d78deaba Mon Sep 17 00:00:00 2001 From: Scott Bronson Date: Thu, 20 Apr 2017 14:43:12 -0700 Subject: [PATCH] :question: add CSS selector tests for the argument operator This is just an example, they don't work yet. --- spec/text-object-spec.coffee | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/spec/text-object-spec.coffee b/spec/text-object-spec.coffee index 1d8330473..7f5a2117c 100644 --- a/spec/text-object-spec.coffee +++ b/spec/text-object-spec.coffee @@ -1747,7 +1747,14 @@ describe "TextObject", -> } """ - describe 'slingle line comma separated text', -> + describe 'without parentheses', -> + it "works with css selectors", -> + set textC: "atom-te|xt-editor, :host {\n}"; ensure 'd a ,', textC: ":host {\n}" + set textC: "atom-text-editor, :ho|st {\n}"; ensure 'd a ,', textC: "atom-text-editor {\n}" + set textC: "atom-te|xt-editor .gutter, :host .gutter {\n}"; ensure 'd a ,', textC: ":host .gutter {\n}" + set textC: "atom-text-editor .gutter, :ho|st .gutter {\n}"; ensure 'd a ,', textC: "atom-text-editor .gutter {\n}" + + describe 'single line comma separated text', -> describe "change 1st arg", -> beforeEach -> set textC: "var a = func(f|irst(1, 2, 3), second(), 3)" it 'change', -> ensure 'c i ,', textC: "var a = func(|, second(), 3)"