Fork me on GitHub
#clojure-spec
<
2022-08-20
>
walterl16:08:55

Hi. 👋 I'm spec'ing a Ring form-params map, which has string keys: (s/def ::params (s/keys :req ["foo" "bar" "baz"])). What is the Right Way to test the values of those params, seeing as one can't do (s/def "foo" ...)? As I understand it, I would have to check the values manually and separately (unlike with (s/keys :req-un [::foo ::bar ::baz])). Nm. I see one can't use string keys with s/keys.