For a Lein project called myproject, I’ve created a file core.clj in the myproject/test/ directory.
(ns myproject.test.core
(:use clojure.test))
;;tests follow
When I try to run the test with “lein test”, it fails with the error:
Exception in thread "main" java.io.FileNotFoundException: Could not locate myproject/test/core__init.class or myproject/test/core.clj on classpath:
From your error, it appears your directory structure is different than what I have used. lein wants core.clj (for test) in the directory that I have posted below. Here is my test directory path that was set up by
lein new utilHere’s the project.clj file, just in case you need it for further clarity.