Skip to content

Instantly share code, notes, and snippets.

@igable
Created July 17, 2015 16:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save igable/70b49702613bb7462da3 to your computer and use it in GitHub Desktop.
Save igable/70b49702613bb7462da3 to your computer and use it in GitHub Desktop.

To test this code in a virtualenv

mkdir mixcoatl
virtualenv mixcoatl
cd mixcoatl/
source bin/activate
git clone https://github.com/igable/mixcoatl.git
cd mixcoatl/
git fetch --all
git checkout feature/muti-endpoint

# install deps needed by nose testing and not regular deployment
pip install nose mock httpretty

# install
python setup.py develop

# go back to the top level virtualenv directory
cd..

Make the data for testing against a live DCM instance:

curl https://gist.githubusercontent.com/igable/73bf1c650553f9336c86/raw/758e084043efc3c4c6df3797ff474663b37007a2/jenkins.sh | bash

# replace the access and secret keys
vim secret-test-data/endpoints.json

Run the nose tests that will create a vm and volune with names like mixcoatl-qa-abcdefgh:

cd mixcoatl/tests/live/

# run the nose tests for a server
nosetests --nocapture test_server.py

# run the nose test for a volume
nosetests --nocapture test_volume.py

If you want to make your own code using this look at the example above this in the PR comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment