Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

used `macro-for` in unfinished*

  • Loading branch information...
commit cf3fab0d2fb00ba7ea29b16be3ab57453133ea1c 1 parent e7734e3
@AlexBaranosky AlexBaranosky authored
Showing with 6 additions and 8 deletions.
  1. +6 −8 src/midje/semi_sweet.clj
View
14 src/midje/semi_sweet.clj
@@ -83,14 +83,12 @@
;;; Interface: unfinished
(defn- unfinished* [names]
- (let [declarations (for [name names]
- `(do
- (defn ~name [& args#]
- (throw (user-error (str "#'" '~name " has no implementation. It's used as a prerequisite in Midje tests."))))
- ;; A reliable way of determining if an `unfinished` function
- ;; has since been defined.
- (alter-meta! (var ~name) assoc :midje/unfinished-fun ~name)))]
- `(do ~@declarations)))
+ (macro-for [name names]
+ `(do
+ (defn ~name [& args#]
+ (throw (user-error (str "#'" '~name " has no implementation. It's used as a prerequisite in Midje tests."))))
+ ;; A reliable way of determining if an `unfinished` function has since been defined.
+ (alter-meta! (var ~name) assoc :midje/unfinished-fun ~name))))
(defmacro unfinished
"Defines a list of names as functions that have no implementation yet. They will

0 comments on commit cf3fab0

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