-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
27 lines (23 loc) · 881 Bytes
/
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
modules = dku_config nlp parallelizer # Add here new libs separated by a whitespace if needed
nlp-setup:
export DICTIONARY_FOLDER_PATH="$(PWD)/core/nlp/resource/dictionaries"; \
export STOPWORDS_FOLDER_PATH="$(PWD)/core/nlp/resource/stopwords"; \
test-one:
@echo "[START] Running unit tests on ${module}..."
@( \
rm -rf env; \
python3 -m venv env/; \
source env/bin/activate; \
pip3 install --upgrade pip; \
pip3 install -r core/${module}/requirements.txt -r tests/requirements.txt; \
export PYTHONPATH="$(PYTHONPATH):$(PWD)"; \
$(MAKE) ${module}-setup; \
pytest tests/${module} --alluredir=tests/allure_report; \
)
@echo "[SUCCESS] Running unit tests on ${module}: Done!"
test-all:
@echo "[START] Running all unit tests..."
@for module in $(modules) ; do \
$(MAKE) module=$${module} test-one; \
done
@echo "[SUCCESS] Running all unit tests: Done!"