Specs relying on a registry and namespace qualified keywords is a mechanism to give you the freedom to put your specs somewhere else.
This makes sense to me. Supposing that I had two maps that shared a keyword, e.g. :name
, and I wanted to spec this keyword differently:
(s/def :my.person/name string?)
(s/def :elonmusk.child/name int?)
Would you then separate those specs into different namespaces (and files)? To me, it seems like a lot to create a new file with a small number of specs, simply to namespace them – which is why the “un-namespaced” form :person/name
worked for me.
Is there convention on where/how to organize specs in a project?