1.3.0 permalink Arrow_down_16x16

inc-report-counter

clojure.test

  • (inc-report-counter name)
Increments the named counter in *report-counters*, a ref to a map.
Does nothing if *report-counters* is nil.

0 Examples top

Log in to add / edit an example.

See Also top

Log in to add a see also.

Plus_12x12 Minus_12x12 Source clojure/test.clj:313 top

(defn inc-report-counter
  "Increments the named counter in *report-counters*, a ref to a map.
  Does nothing if *report-counters* is nil."
  {:added "1.1"}
  [name]
  (when *report-counters*
    (dosync (commute *report-counters* assoc name
                     (inc (or (*report-counters* name) 0))))))
Vars in clojure.test/inc-report-counter:
Used in 0 other vars

Comments top

No comments for inc-report-counter. Log in to add a comment.