diff options
author | Adam Kocoloski <adam@cloudant.com> | 2011-02-09 11:01:54 -0500 |
---|---|---|
committer | Adam Kocoloski <adam@cloudant.com> | 2011-02-09 12:40:46 -0500 |
commit | 435aed29315cef73a9df9bf35a7fb6bbef6f9559 (patch) | |
tree | a21828ab48153d5b995d4e594c76333520d67bce | |
parent | 62fadabc47bcbbdb2a06367b17339d46dd1d3150 (diff) |
Fix and simplify environment for etap tests
BugzID: 11797
-rw-r--r-- | Makefile | 6 | ||||
-rw-r--r-- | apps/couch/src/test_util.erl | 15 |
2 files changed, 6 insertions, 15 deletions
@@ -26,10 +26,10 @@ clean: @cd couchjs && python scons/scons.py --clean @./rebar clean -check: +# compile is required here because of cross-dependencies between apps +check: compile @./rebar eunit - @ERL_FLAGS="-pa `pwd`/apps/couch/ebin `pwd`/apps/couch/test/etap" \ - prove apps/couch/test/etap/*.t + @ERL_FLAGS="-pa `pwd`/apps/couch/ebin" prove apps/couch/test/etap/*.t dist: compile @rm -rf rel/bigcouch diff --git a/apps/couch/src/test_util.erl b/apps/couch/src/test_util.erl index ce6a20ef..e43338e7 100644 --- a/apps/couch/src/test_util.erl +++ b/apps/couch/src/test_util.erl @@ -15,20 +15,11 @@ -export([init_code_path/0]). -export([source_file/1, build_file/1]). -srcdir() -> - "@abs_top_srcdir@". - -builddir() -> - "@abs_top_builddir@". - init_code_path() -> - Paths = ["etap", "couch", "oauth", "ibrowse", "mochiweb"], - lists:foreach(fun(Name) -> - code:add_pathz(filename:join([builddir(), "ebin", Name])) - end, Paths). + code:load_abs("apps/couch/test/etap/etap"). source_file(Name) -> - filename:join([srcdir(), Name]). + filename:join(["apps/couch", Name]). build_file(Name) -> - filename:join([builddir(), Name]). + filename:join(["apps/couch", Name]). |