Open ilmoraunio opened 7 years ago
A way to bypass the problem is to require the tests in a separate function call and require the namespace-under-test under ns
:
(ns training-day-test
(:require [training-day :refer :all]))
(require 'iloveponies.tests.training-day :reload)
For me it's still unclear, if it's a bug in midje or a feature of clojure.
Description
lein midje :autotest
will not rerun tests in external dependencies after modifying .clj files undersrc/
folder.Steps to reproduce bug (example project)
training-day
repositorygit clone https://github.com/iloveponies/training-day.git
lein midje :autotest
. 6 checks should fail.square
fn insrc/training_day.clj
to return(* x x)
instead of":("
.Actual expectation
lein midje :autotest
should really be returning "3 checks failed. (But 3 succeeded.)" in step 4, but it doesn't seem to reload the external dependencies where the tests are located.The test file
training_day_test.clj
contains only a reference to a namespace containing all of the tests:This is the only test file in this project.
Related to #48. Also related issues from iloveponies' repositories: