slagyr/speclj — pull request #26 by mylesmegyesi (2012-10-06 14:03:05+00:00)
Title: Refactors components to be able to add 'def's to a spec.

This refactoring allows helper functions to be defined within a spec. For example...

``` clojure
(describe "defs can be added to specs"
(defn a-fn [] true)

(it "uses the def within the describe"
(should (a-fn))))
```

Previously, helper functions had to be defined at the top of the file. When writing a large spec file, this can be very cumbersome and hard to read. This refactoring should solve this problem.