2 (load-file "../realgud/debugger/rdebug/init.el")
3 (load-file "./regexp-helper.el")
7 (setup-regexp-vars realgud-rdebug-pat-hash)
8 (setq rails-bt (gethash "rails-backtrace" realgud-rdebug-pat-hash))
10 ;; FIXME: we get a void variable somewhere in here when running
11 ;; even though we define it in lexical-let. Dunno why.
12 ;; setq however will workaround this.
13 (setq text " from /usr/local/bin/irb:12:in `<main>'")
14 (note "traceback location matching")
15 (lexical-let ((text " from /usr/local/bin/irb:12:in `<main>'"))
16 (assert-t (numberp (loc-match text helper-tb)) "basic traceback location")
17 (assert-equal "/usr/local/bin/irb"
18 (match-string (realgud-loc-pat-file-group helper-tb)
20 "extract traceback file name")
22 (match-string (realgud-loc-pat-line-group helper-tb)
23 text) "extract traceback line number")
26 (lexical-let ((text "Breakpoint 1 file /usr/bin/irb, line 10\n"))
27 (assert-t (numberp (loc-match text helper-bps)) "basic breakpoint location")
28 (assert-equal "/usr/bin/irb"
29 (match-string (realgud-loc-pat-file-group helper-bps)
30 text) "extract breakpoint file name")
32 (match-string (realgud-loc-pat-line-group helper-bps)
33 text) "extract breakpoint line number")
37 (set (make-local-variable 'prompt-pat)
38 (gethash "prompt" realgud-rdebug-pat-hash))
39 (prompt-match "(rdb:1) ")