emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/multiple-cursors 49027c6 262/434: Add basic tests for 'mc/


From: ELPA Syncer
Subject: [nongnu] elpa/multiple-cursors 49027c6 262/434: Add basic tests for 'mc/mark-all-dwim'
Date: Sat, 7 Aug 2021 09:20:38 -0400 (EDT)

branch: elpa/multiple-cursors
commit 49027c67178afadb314c885e5649b421c4b6de72
Author: Maciej Katafiasz <mathrick@gmail.com>
Commit: Maciej Katafiasz <mathrick@gmail.com>

    Add basic tests for 'mc/mark-all-dwim'
---
 features/mark-all-dwim.feature | 26 ++++++++++++++++++++++++++
 features/support/env.el        |  1 +
 2 files changed, 27 insertions(+)

diff --git a/features/mark-all-dwim.feature b/features/mark-all-dwim.feature
index 9eca714..7870a6a 100644
--- a/features/mark-all-dwim.feature
+++ b/features/mark-all-dwim.feature
@@ -17,6 +17,16 @@ Feature: Mark all do-what-I-mean
     (defun abc (hmm) (message hmm))
     (defun def (ghi) (message some-other-ghi))
     """
+    When I press "C-g"
+    And I go to the front of the word "hmm"
+    And I press "C-$"
+    And I type "foo"
+    Then I should see:
+    """
+    (defun abc (foo) (message foo))
+    (defun def (ghi) (message some-other-ghi))
+    """
+    
 
   Scenario: Mark all symbols by pressing twice
     Given I turn on emacs-lisp-mode
@@ -36,3 +46,19 @@ Feature: Mark all do-what-I-mean
     (defun abc (hmm) (message hmm))
     (defun def (hmm) (message hmm))
     """
+    When I press "C-g"
+    And I press "M-> RET"
+    And I insert:
+    """
+    (defun def (hmm-hmm) (message hmm))
+    """
+    And I go to the front of the word "hmm"
+    And I press "C-$"
+    And I press "C-$"
+    And I type "humm"
+    Then I should see:
+    """
+    (defun abc (humm) (message humm))
+    (defun def (humm) (message humm))
+    (defun def (humm-humm) (message humm))
+    """
diff --git a/features/support/env.el b/features/support/env.el
index 4f6af30..3ce7c91 100644
--- a/features/support/env.el
+++ b/features/support/env.el
@@ -24,6 +24,7 @@
  (global-set-key (kbd "C-<") 'mc/mark-previous-like-this)
  (global-set-key (kbd "M-!") 'mc/mark-all-like-this)
  (global-set-key (kbd "M-$") 'mc/mark-all-like-this-dwim)
+ (global-set-key (kbd "C-$") 'mc/mark-all-dwim)
  (global-set-key (kbd "M-#") 'mc/mark-all-in-region)
  (global-set-key (kbd "H-0") 'mc/insert-numbers)
  (global-set-key (kbd "H-1") 'mc/reverse-regions)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]