Skip to content
Browse files

Fixed problem with midje-recheck-last-fact-checked.

Always used the current namespace instead of the namespace where the
fact were defined.
  • Loading branch information...
1 parent 025be27 commit 256bfdff6a3488b1e93734eba4741e1858a8e2fe @bonega bonega committed Oct 15, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 midje-mode.el
4 midje-mode.el
@@ -9,6 +9,7 @@
(defvar midje-comments ";.;.")
(defvar last-checked-midje-fact nil)
+(defvar last-checked-midje-fact-ns nil)
(defvar midje-fact-regexp "^(facts?\\([[:space:]]\\|$\\)")
(defvar midje-syntax-table nil)
@@ -198,6 +199,7 @@ Check that fact and also save it for use of
+ (setq last-checked-midje-fact-ns nrepl-buffer-ns)
(let ((string (save-excursion
(buffer-substring-no-properties (mark) (point)))))
@@ -217,7 +219,7 @@ the last fact checked (by `midje-check-fact-near-point')."
(nrepl-send-string last-checked-midje-fact
(nrepl-check-fact-handler (current-buffer))
- nrepl-buffer-ns))
+ last-checked-midje-fact-ns))
(defun midje-check-fact ()
"If on or near a Midje fact, check it with

0 comments on commit 256bfdf

Please sign in to comment.
Something went wrong with that request. Please try again.