er-basic-expansions.feature (1864B)
1 Feature: Basic expansions 2 3 Scenario: Mark URL 4 Given there is no region selected 5 And I insert "Here is the link: http://emacsrocks.com :-)" 6 When I place the cursor after "http" 7 And I press "C-@" 8 And I press "C-@" 9 Then the region should be "http://emacsrocks.com" 10 11 Scenario: Mark email 12 Given there is no region selected 13 And I insert "Here is the email: sample@example.com :-)" 14 When I place the cursor after "sample" 15 And I press "C-@" 16 And I press "C-@" 17 Then the region should be "sample@example.com" 18 19 Scenario: Mark symbol with prefix 20 Given I turn on emacs-lisp-mode 21 And I insert "(set 'abc 123)" 22 When I place the cursor after "abc" 23 And I press "C-@" 24 And I press "C-@" 25 Then the region should be "'abc" 26 27 Scenario: Mark string 28 Given I turn on emacs-lisp-mode 29 And I insert "(set 'abc "123")" 30 When I place the cursor after "2" 31 And I press "C-@" 32 And I press "C-@" 33 Then the region should be ""123"" 34 35 Scenario: Mark word 36 Given I turn on emacs-lisp-mode 37 And I insert "(set-default 'abc 123)" 38 When I place the cursor after "f" 39 And I press "C-@" 40 Then the region should be "default" 41 42 Scenario: Mark symbol 43 Given I turn on emacs-lisp-mode 44 And I insert "(set-default 'abc 123)" 45 When I place the cursor after "f" 46 And I press "C-@" 47 And I press "C-@" 48 Then the region should be "set-default" 49 50 Scenario: Mark method call 51 Given I turn on js-mode 52 And I insert "document.write('abc');" 53 When I place the cursor after "write" 54 And I press "C-@" 55 And I press "C-@" 56 Then the region should be "document.write('abc')" 57 58 Scenario: Mark current pair 59 Given I turn on emacs-lisp-mode 60 And I insert "((foo)(bar))" 61 When I place the cursor after "oo)" 62 And I press "C-@" 63 Then the region should be "(bar)" 64