Klement Sekera | f62ae12 | 2016-10-11 11:47:09 +0200 | [diff] [blame] | 1 | PYTHON_VENV_PATH=$(PYTHON_PATH)/virtualenv |
Damjan Marion | f56b77a | 2016-10-03 19:44:57 +0200 | [diff] [blame] | 2 | |
Klement Sekera | f62ae12 | 2016-10-11 11:47:09 +0200 | [diff] [blame] | 3 | test: clean |
| 4 | @virtualenv $(PYTHON_VENV_PATH) |
| 5 | @bash -c "source $(PYTHON_VENV_PATH)/bin/activate && pip install scapy" |
| 6 | @bash -c "source $(PYTHON_VENV_PATH)/bin/activate && pip install pexpect" |
| 7 | @bash -c "source $(PYTHON_VENV_PATH)/bin/activate && cd $(WS_ROOT)/vpp-api/python && python setup.py install" |
| 8 | @bash -c "source $(PYTHON_VENV_PATH)/bin/activate && python run_tests.py discover -p test_$(TEST)\"*.py\"" |
| 9 | |
| 10 | retest: clean |
| 11 | @bash -c "source $(PYTHON_VENV_PATH)/bin/activate && python run_tests.py discover -p test_$(TEST)\"*.py\"" |
| 12 | |
| 13 | .PHONY: clean doc |
| 14 | |
| 15 | clean: |
| 16 | @rm -f /dev/shm/vpp-unittest-* |
| 17 | @rm -rf /tmp/vpp-unittest-* |
| 18 | |
| 19 | doc: |
| 20 | @virtualenv $(PYTHON_VENV_PATH) |
| 21 | @bash -c "source $(PYTHON_VENV_PATH)/bin/activate && pip install sphinx" |
| 22 | @bash -c "source $(PYTHON_VENV_PATH)/bin/activate && make -C doc html" |