added a comment - - edited
Thanks for the feedback and the explanation of the :fail vector.
As discussed, I've added the filename test for :clj only. Not only is there no relevant namespace reference in the :cljs file path, the filename itself is different depending on the output target.
Regarding the additional test, I noticed that my merge in the first patch left a redundant version of the initial can-report-shrinking test. I've removed that initial version. Thanks for bringing it to my attention.
Regarding rewriting the assert-expr defmethod to reduce the number of namespaces, I don't believe it's possible to reduce it to one, at least not for JVM ClojureScript. The reason is that the CLJ and CLJS versions require different clj files – clojure.test and cljs.test, respectively – during the CLJ compilation stage. As far as I know, there's no way to indicate in this CLJ file, require library clojure.test when the ultimate target is CLJ, and cljs.test when it's going to be included in a CLJS file down the road. This is what requires the separate check.clj and check/cljs-macros.clj files. If you know of a method or an implementation that does this, please let me know. I've done quite a bit of re-reading of references on the topic, but I admittedly am still not as strong in my understanding of ClojureScript compilation to be sure I've exhausted the available options.
The check/impl.cljc file is there to keep the code DRY.
I've made a couple of changes which I hope are improvments. I collapsed the check.clj and check.cljs files into a single check.cljc file. I've also renamed the check/cljs_macros.clj file to check/cljs.clj as it is cljs-specific but doesn't include any macro definitions. A file named check/cljs.clj (namespace clojure.test.check.clojure-test-check.cljs is a bit confusing, but the longer alternative check/check_cljs.clj with the namespace clojure.test.check.clojure-test.check.check-cljs doesn't seem to be any better.
For reference, here's a summary of the conditional dependencies reflecting the updated patch:
:clj version dependencies
- clojure-test.check (.cljc:clj) – clojure.test/assert-expr defmethod
- clojure-test.check.impl (.cljc/:clj) – check? defn
- clojure.test (.clj) – clojure.test/assert-expr defmulti
:cljs version dependencies
- clojure-test.check (.cljc:cljs)
- clojure-test.check.impl (.cljc:cljs) – check? and check-results cljs defns
- clojure-test.check.cljs (.clj) – cljs.test/assert-expr defmethod
- clojure-test.check.impl (.cljc:clj) – check? reference
- cljs.test (.cljc:clj) – cljs.test/assert-expr defmulti