1# Set this prefix to where you want to install the plugin
2PREFIX=/usr/local
3
4NOSE0=nosetests -vs --with-doctest --doctest-tests --detailed-errors
5NOSE=nosetests -vvs --with-ipdoctest --doctest-tests --doctest-extension=txt \
6--detailed-errors
7
8SRC=ipdoctest.py setup.py ../decorators.py
9
10# Default target for clean 'make'
11default: interactiveshell
12
13# The actual plugin installation
14plugin: IPython_doctest_plugin.egg-info
15
16# Simple targets that test one thing
17simple: plugin simple.py
18	$(NOSE) simple.py
19
20dtest: plugin dtexample.py
21	$(NOSE) dtexample.py
22
23rtest: plugin test_refs.py
24	$(NOSE) test_refs.py
25
26test: plugin dtexample.py
27	$(NOSE) dtexample.py test*.py test*.txt
28
29deb: plugin dtexample.py
30	$(NOSE) test_combo.txt
31
32# IPython tests
33deco:
34	$(NOSE0) IPython.testing.decorators
35
36magic: plugin
37	$(NOSE) IPython.core.magic
38
39excolors: plugin
40	$(NOSE) IPython.core.excolors
41
42interactiveshell: plugin
43	$(NOSE)  IPython.core.interactiveshell
44
45strd: plugin
46	$(NOSE) IPython.core.strdispatch
47
48engine: plugin
49	$(NOSE) IPython.kernel
50
51tf: plugin
52	$(NOSE) IPython.config.traitlets
53
54# All of ipython itself
55ipython: plugin
56	$(NOSE) IPython
57
58
59# Combined targets
60sr: rtest strd
61
62base: dtest rtest test strd deco
63
64quick: base interactiveshell ipipe
65
66all: base ipython
67
68# Main plugin and cleanup
69IPython_doctest_plugin.egg-info: $(SRC)
70	pip install . --prefix=$(PREFIX)
71	touch $@
72
73clean:
74	rm -rf IPython_doctest_plugin.egg-info *~ *pyc build/ dist/
75