Hello all, how can I use a clojure file that can be used for all my test files? I tried using in test/clj/util/common.clj
but it says that can´t find it
I have the same fixture
to my tests, so I have the common thing for all tests
@fabrao You need to require
it into each namespace that references it.
@seancorfield I did it, can I create any clojure file in test folder to include it in my tests?
(ns db.notificacao.atributo-test
(:require
[clojure.test :refer :all]
[db.notificacao.regra :refer :all]
[db.notificacao.atributo :refer :all]
[util.comum :refer :all] <-
))
Unhandled java.io.FileNotFoundException
Could not locate util/comum__init.class or util/comum.clj on
classpath.
If I go to the file and load it in repl, it works
so I´m little lost how it works
If you are in the REPL, can you (require 'db.notificacao.atributo-test)
?
yes, only the comum.clj
is not loading
nevermind, it´s easier to include fixture in each test file