Skip to content

Commit 7a1ef22

Browse files
authored
Merge pull request #1030 from jdufresne/no-editable
Avoid installing package in editable mode for testing
2 parents 31e87c3 + 2b608b4 commit 7a1ef22

File tree

5 files changed

+10
-15
lines changed

5 files changed

+10
-15
lines changed

Makefile

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ isort_check_only:
1111

1212
example:
1313
DJANGO_SETTINGS_MODULE=example.settings \
14-
django-admin runserver
14+
python -m django runserver
1515

1616
jshint: node_modules/jshint/bin/jshint
1717
./node_modules/jshint/bin/jshint debug_toolbar/static/debug_toolbar/js/*.js
@@ -21,24 +21,24 @@ node_modules/jshint/bin/jshint:
2121

2222
test:
2323
DJANGO_SETTINGS_MODULE=tests.settings \
24-
django-admin test $${TEST_ARGS:-tests}
24+
python -m django test $${TEST_ARGS:-tests}
2525

2626
test_selenium:
2727
DJANGO_SELENIUM_TESTS=true DJANGO_SETTINGS_MODULE=tests.settings \
28-
django-admin test $${TEST_ARGS:-tests}
28+
python -m django test $${TEST_ARGS:-tests}
2929

3030
coverage:
3131
python --version
3232
coverage erase
3333
DJANGO_SETTINGS_MODULE=tests.settings \
34-
coverage run `which django-admin` test -v2 $${TEST_ARGS:-tests}
34+
coverage run -m django test -v2 $${TEST_ARGS:-tests}
3535
coverage report
3636
coverage html
3737

3838
translatable_strings:
39-
cd debug_toolbar && django-admin makemessages -l en --no-obsolete
39+
cd debug_toolbar && python -m django makemessages -l en --no-obsolete
4040
@echo "Please commit changes and run 'tx push -s' (or wait for Transifex to pick them)"
4141

4242
update_translations:
4343
tx pull -a --minimum-perc=10
44-
cd debug_toolbar && django-admin compilemessages
44+
cd debug_toolbar && python -m django compilemessages

docs/contributing.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ the libraries required for working on the Debug Toolbar::
3232

3333
You can run now run the example application::
3434

35-
$ DJANGO_SETTINGS_MODULE=example.settings django-admin migrate
36-
$ DJANGO_SETTINGS_MODULE=example.settings django-admin runserver
35+
$ DJANGO_SETTINGS_MODULE=example.settings python -m django migrate
36+
$ DJANGO_SETTINGS_MODULE=example.settings python -m django runserver
3737

3838
For convenience, there's an alias for the second command::
3939

example/README.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ the debug toolbar, ie. the directory that contains ``example/``.
2222

2323
Before running the example for the first time, you must create a database::
2424

25-
$ PYTHONPATH=. django-admin migrate --settings=example.settings
25+
$ python -m django migrate --settings=example.settings
2626

2727
Then you can use the following command to run the example::
2828

29-
$ PYTHONPATH=. django-admin runserver --settings=example.settings
29+
$ python -m django runserver --settings=example.settings

requirements_dev.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
# The debug toolbar itself
2-
3-
-e .
4-
51
# Runtime dependencies
62

73
Django

tox.ini

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ setenv =
1919
PYTHONPATH = {toxinidir}
2020
whitelist_externals = make
2121
pip_pre = True
22-
usedevelop = true
2322
commands = make coverage TEST_ARGS='{posargs:tests}'
2423

2524
[testenv:flake8]

0 commit comments

Comments
 (0)