forked from ErlyORM/boss_db
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
45 lines (31 loc) · 1.08 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
ERL=erl
REBAR=./rebar
DB_CONFIG_DIR=priv/test_db_config
.PHONY: deps get-deps test
all:
@$(REBAR) get-deps
@$(REBAR) compile
boss_db:
@$(REBAR) compile skip_deps=true
clean:
@$(REBAR) clean
get-deps:
@$(REBAR) get-deps
deps:
@$(REBAR) compile
test:
@$(REBAR) skip_deps=true eunit
compile_db_test:
@$(REBAR) clean skip_deps=true
@$(REBAR) --config "rebar.test.config" compile skip_deps=true
test_db_mock: compile_db_test
$(ERL) -pa ebin -pa deps/*/ebin -run boss_db_test start -config $(DB_CONFIG_DIR)/mock -noshell
test_db_mysql: compile_db_test
$(ERL) -pa ebin -pa deps/*/ebin -run boss_db_test start -config $(DB_CONFIG_DIR)/mysql -noshell
test_db_pgsql: compile_db_test
$(ERL) -pa ebin -pa deps/*/ebin -run boss_db_test start -config $(DB_CONFIG_DIR)/pgsql -noshell
test_db_mongodb: compile_db_test
echo "db.boss_db_test_models.remove();"|mongo boss_test
$(ERL) -pa ebin -pa deps/*/ebin -run boss_db_test start -config $(DB_CONFIG_DIR)/mongodb -noshell
test_db_riak: compile_db_test
$(ERL) -pa ebin -pa deps/*/ebin -run boss_db_test start -config $(DB_CONFIG_DIR)/riak -noshell