[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 70ead82 184/215: Correct "breakpoint deleted" regexp
From: |
Rocky Bernstein |
Subject: |
[elpa] master 70ead82 184/215: Correct "breakpoint deleted" regexp |
Date: |
Sat, 30 Jul 2016 14:49:04 +0000 (UTC) |
branch: master
commit 70ead82eccdcadcf5b6dcb2d7b0d955533048051
Author: rocky <address@hidden>
Commit: rocky <address@hidden>
Correct "breakpoint deleted" regexp
test-regexp-zshdb.el: beef up and sync to corresponding bashdb test.
Makefile.am: make "make check-short" in this directory work
---
realgud/lang/posix-shell.el | 2 +-
test/Makefile.am | 4 ++--
test/test-regexp-bashdb.el | 2 +-
test/test-regexp-zshdb.el | 48 +++++++++++++++++++++++++++++++------------
4 files changed, 39 insertions(+), 17 deletions(-)
diff --git a/realgud/lang/posix-shell.el b/realgud/lang/posix-shell.el
index 54216c2..6fff596 100644
--- a/realgud/lang/posix-shell.el
+++ b/realgud/lang/posix-shell.el
@@ -103,7 +103,7 @@ traceback) line." )
;; Removed 1 breakpoint(s).
(defconst realgud:POSIX-debugger-brkpt-del-pat
(make-realgud-loc-pat
- :regexp (format "^Removed %s breakpoint(s).\n"
+ :regexp (format "^Deleted breakpoint %s.?\n"
realgud:regexp-captured-num)
:num 1))
diff --git a/test/Makefile.am b/test/Makefile.am
index c0e7ede..c56f333 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -50,11 +50,11 @@ check-elget: $(EL_GET_CHECK_FILES)
#: Run all tests with minimum verbosity
check-short:
- $(MAKE) check 2>&1 | ruby ../make-check-filter.rb
+ $(MAKE) check 2>&1 | ruby make-check-filter.rb
#: Run all tests with minimum verbosity via el-get
check-short-elget:
- $(MAKE) check-elget 2>&1 | ruby ../make-check-filter.rb
+ $(MAKE) check-elget 2>&1 | ruby make-check-filter.rb
test-%.run:
(cd $(top_srcdir)/test && $(EMACS) --batch --no-site-file --no-splash
--load $(@:.run=.el))
diff --git a/test/test-regexp-bashdb.el b/test/test-regexp-bashdb.el
index 00830e9..35da88d 100644
--- a/test/test-regexp-bashdb.el
+++ b/test/test-regexp-bashdb.el
@@ -104,7 +104,7 @@
(match-end file-group)))
(note "breakpoint delete matching")
-(setq test-text "Removed 1 breakpoint(s).\n")
+(setq test-text "Deleted breakpoint 1\n")
(assert-t (numberp (loc-match test-text bp-del-pat)) "breakpoint delete
matching")
diff --git a/test/test-regexp-zshdb.el b/test/test-regexp-zshdb.el
index c9ff95a..654d2ef 100644
--- a/test/test-regexp-zshdb.el
+++ b/test/test-regexp-zshdb.el
@@ -7,6 +7,24 @@
(test-simple-start)
+(eval-when-compile
+ (defvar file-group)
+ (defvar frame-re)
+ (defvar line-group)
+ (defvar num-group)
+ (defvar test-pos)
+ (defvar prompt-pat)
+ (defvar realgud:zshdb-pat-hash)
+ (defvar realgud-pat-bt)
+ (defvar test-s1)
+ (defvar test-text)
+ (defvar brkpt-del)
+ (defvar bp-del-pat)
+)
+
+(set (make-local-variable 'bp-del-pat)
+ (gethash "brkpt-del" realgud:zshdb-pat-hash))
+
(setq prompt-pat (gethash "prompt" realgud:zshdb-pat-hash))
(setq frame-pat (gethash "debugger-backtrace" realgud:zshdb-pat-hash))
@@ -18,7 +36,7 @@
(note "zshdb frame matching")
(note "debugger-backtrace")
-(setq s1
+(setq test-s1
"->0 in file `/etc/apparmor/functions' at line 24
##1 /etc/apparmor/functions called from file `/etc/init.d/apparmor' at line 35
##2 /etc/init.d/apparmor called from file `/usr/local/bin/zshdb' at line 129
@@ -27,44 +45,48 @@
(setq num-group (realgud-loc-pat-num frame-pat))
(setq file-group (realgud-loc-pat-file-group frame-pat))
(setq line-group (realgud-loc-pat-line-group frame-pat))
-(assert-equal 0 (string-match frame-re s1))
-(assert-equal "0" (substring s1
+(assert-equal 0 (string-match frame-re test-s1))
+(assert-equal "0" (substring test-s1
(match-beginning num-group)
(match-end num-group)))
(assert-equal "/etc/apparmor/functions"
- (substring s1
+ (substring test-s1
(match-beginning file-group)
(match-end file-group)))
(assert-equal "24"
- (substring s1
+ (substring test-s1
(match-beginning line-group)
(match-end line-group)))
(setq pos (match-end 0))
-(assert-equal 49 (string-match frame-re s1 pos))
-(assert-equal "1" (substring s1
+(assert-equal 49 (string-match frame-re test-s1 pos))
+(assert-equal "1" (substring test-s1
(match-beginning num-group)
(match-end num-group)))
(assert-equal "/etc/init.d/apparmor"
- (substring s1
+ (substring test-s1
(match-beginning file-group)
(match-end file-group)))
(assert-equal "35"
- (substring s1
+ (substring test-s1
(match-beginning line-group)
(match-end line-group)))
(setq pos (match-end 0))
-(assert-equal 128 (string-match frame-re s1 pos))
-(assert-equal "2" (substring s1
+(assert-equal 128 (string-match frame-re test-s1 pos))
+(assert-equal "2" (substring test-s1
(match-beginning num-group)
(match-end num-group)))
(assert-equal "/usr/local/bin/zshdb"
- (substring s1
+ (substring test-s1
(match-beginning file-group)
(match-end file-group)))
(assert-equal "129"
- (substring s1
+ (substring test-s1
(match-beginning line-group)
(match-end line-group)))
+(note "breakpoint delete matching")
+(setq test-text "Deleted breakpoint 1\n")
+(assert-t (numberp (loc-match test-text bp-del-pat)) "breakpoint delete
matching")
+
(end-tests)
- [elpa] master 8d7961d 212/215: Need to put back el-get-install.el for travis, (continued)
- [elpa] master 8d7961d 212/215: Need to put back el-get-install.el for travis, Rocky Bernstein, 2016/07/30
- [elpa] master e68e3a2 133/215: Add a few bindings to shortkey-mode, Rocky Bernstein, 2016/07/30
- [elpa] master 6500858 081/215: Try to tidy badges a little, Rocky Bernstein, 2016/07/30
- [elpa] master c633f3f 136/215: Ignore safe-mode setting when clicking a toolbar button, Rocky Bernstein, 2016/07/30
- [elpa] master 81f0b58 172/215: Merge pull request #114 from rocky/default-hash, Rocky Bernstein, 2016/07/30
- [elpa] master d2b8d13 134/215: Remove key argument of realgud:cmd-remap, Rocky Bernstein, 2016/07/30
- [elpa] master bf1cd9f 087/215: Travis emacs doesn't do font-lock-ensure. Use older form for now, Rocky Bernstein, 2016/07/30
- [elpa] master 8e00edc 174/215: Further cleanup in cmds.el: remove unused arguments, Rocky Bernstein, 2016/07/30
- [elpa] master 6429d94 129/215: Revert "Manually generate "recursive" autoloads for subdirectories", Rocky Bernstein, 2016/07/30
- [elpa] master 1ff6720 189/215: Merge pull request #127 from realgud/quit-confirm, Rocky Bernstein, 2016/07/30
- [elpa] master 70ead82 184/215: Correct "breakpoint deleted" regexp,
Rocky Bernstein <=
- [elpa] master b71750a 193/215: Relax deleted breakpoint regexp in PDB to support Python 2 and 3, Rocky Bernstein, 2016/07/30
- [elpa] master 2f30f42 176/215: Merge pull request #119 from realgud/improve-break-C-u, Rocky Bernstein, 2016/07/30
- [elpa] master cbfa182 203/215: Improve realgud:run-process docstring, Rocky Bernstein, 2016/07/30
- [elpa] master 333a946 104/215: Merge pull request #74 from rocky/ipdb, Rocky Bernstein, 2016/07/30
- [elpa] master 2316417 205/215: Reassign more copyrights to FSF, Rocky Bernstein, 2016/07/30
- [elpa] master 703e087 185/215: Correct cmd capabilities for perldb and trepanjs, Rocky Bernstein, 2016/07/30
- [elpa] master d367cab 196/215: Correct python trepan enable/disable patterns, Rocky Bernstein, 2016/07/30
- [elpa] master 5a84817 178/215: Fix invalid references to realgud:loc-follow, Rocky Bernstein, 2016/07/30
- [elpa] master 8edfb04 215/215: Not needed for elpa, Rocky Bernstein, 2016/07/30
- [elpa] master d97bf08 179/215: Update doc links, Rocky Bernstein, 2016/07/30