-
Notifications
You must be signed in to change notification settings - Fork 323
/
Makefile
55 lines (41 loc) · 1.79 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
46
47
48
49
50
51
52
53
54
55
all: check_dependencies unit functional doctest
filename=lettuce-`python -c 'import lettuce;print lettuce.version'`.tar.gz
export PYTHONPATH:= ${PWD}
export LETTUCE_DEPENDENCIES:= nose mox sphinx lxml django fuzzywuzzy mock
check_dependencies:
@echo "Checking for dependencies to run tests ..."
@for dependency in `echo $$LETTUCE_DEPENDENCIES`; do \
python -c "import $$dependency" 2>/dev/null || (echo "You must install $$dependency in order to run lettuce's tests" && exit 3) ; \
done
unit: clean
@echo "Running unit tests ..."
@nosetests -s --verbosity=2 --with-coverage --cover-erase --cover-inclusive tests/unit --cover-package=lettuce
functional: clean
@echo "Running functional tests ..."
@nosetests --stop -s --verbosity=2 --with-coverage --cover-erase --cover-inclusive tests/functional --cover-package=lettuce
integration: clean
@echo "Running integration tests ..."
@nosetests --stop -s --verbosity=2 tests/integration
doctest: clean
@cd docs && make doctest
documentation:
@cd docs && make html
clean:
@printf "Cleaning up files that are already in .gitignore... "
@for pattern in `cat .gitignore`; do find . -name "$$pattern" -delete; done
@echo "OK!"
withdraw-documentation:
@printf 'Removing current documentation ...'
@ssh [email protected] rm -rf lettuce.it/public/*
@echo "DONE!"
deploy-documentation:documentation withdraw-documentation
@printf 'Deploying documentation to http://lettuce.it ...'
@cd ./docs/_build/html && tar -zcp * | ssh [email protected] "tar zxp -C ./lettuce.it/public/"
@echo "DONE!"
deploy: deploy-documentation
release: clean doctest deploy-documentation publish
@printf "Exporting to $(filename)... "
@tar czf $(filename) lettuce setup.py README.md COPYING
@echo "DONE!"
publish:
@python setup.py sdist register upload