Skip to content

Commit

Permalink
Fix to avoid sandbox violation when installing node as bdist egg
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Vetter committed Mar 16, 2013
1 parent 6c82e78 commit a777b6c
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 4 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Expand Up @@ -5,6 +5,7 @@ python:
env:
- SETUP_COMMAND="install"
- SETUP_COMMAND="build"
- SETUP_COMMAND="-q bdist_egg --dist-dir /tmp/easy_install/virtual-node"
install:
- python setup.py $SETUP_COMMAND
script:
Expand Down
7 changes: 7 additions & 0 deletions setup.py
Expand Up @@ -21,6 +21,13 @@
from distutils.command.build import build as _build


from setuptools.sandbox import DirectorySandbox
def violation(*args):
pass
DirectorySandbox._old = DirectorySandbox._violation
DirectorySandbox._violation = violation


class node_bdist_egg(_bdist_egg):

#def __init__(self, *args, **kwargs):
Expand Down
14 changes: 10 additions & 4 deletions tox.ini
@@ -1,7 +1,13 @@
#content of: tox.ini , put in same dir as setup.py
[tox]
envlist = py26,py27,py27-devel
envlist = py26,py27,py27-build
[testenv:py26,py27]
commands = python setup.py install
[testenv:py27-devel]
commands = python setup.py devel
commands =
python setup.py install
nosetests tests
[testenv:py27-build]
site-packages=True
distribute=False
commands =
python setup.py build
nosetests tests

0 comments on commit a777b6c

Please sign in to comment.