Skip to content
This repository has been archived by the owner on Sep 26, 2022. It is now read-only.

Get all tests to work and document how to run tests #5

Closed
toenuff opened this issue Dec 29, 2016 · 4 comments
Closed

Get all tests to work and document how to run tests #5

toenuff opened this issue Dec 29, 2016 · 4 comments

Comments

@toenuff
Copy link
Contributor

toenuff commented Dec 29, 2016

This issue should remain open until all tests are fixed and how to run them are documented

Here are the steps to install dependencies and run tests on a clean ubuntu box. There are a number of errors that are still occurring and will call them out independently in issues of their own. These instructions should be wrapped in setuptools and each module installed locally with setup.py. However, until that time, I'm just adding them here so that others can help hack away at getting the tests to work.

sudo apt-get install python-dev
sudo apt-get install krb5-config (just click enter on default kerb realm)
sudo apt-get install libkrb5-dev
sudo apt-get install python-pip

sudo locale-gen en_US
sudo update-locale

sudo pip install nose
sudo pip install kazoo
sudo pip install mock
sudo pip install jinja2
sudo pip install flask
sudo pip install tornado
sudo pip install enum34
sudo pip install ldap3
sudo pip install kerberos
sudo pip install decorator
sudo pip install dnspython
sudo pip install jsonschema
sudo pip install netifaces
sudo pip install flask_restplus
sudo pip install requests_kerberos
sudo pip install urllib2_kerberos
sudo pip install numpy
sudo pip install pandas
sudo pip install simplejson
sudo pip install websocket
sudo pip install jsonpointer --upgrade

The following modules do not exist on the Internet and probably need to be dropped/rethought re: why they are needed in public version of Treadmill:
webauthd
plugin.fs
proiddb

With the above in place, cd to treadmill dir and run:
nosetests

@toenuff
Copy link
Contributor Author

toenuff commented Dec 29, 2016

With Pull Request #7 , all tests are working except for those outlined in Issue #10 that will require Morgan Stanley fixes. Where should I store the info for running tests? Wikis are locked down so should I just add to readmde for now so I can close this issue?

@gaocegege
Copy link
Contributor

Hi, I follows the instructions and got many errors:

ERROR: Failure: IOError ([Errno 2] No such file or directory)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/ist/venvs/treadmill-py2/local/lib/python2.7/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/home/ist/venvs/treadmill-py2/local/lib/python2.7/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/home/ist/venvs/treadmill-py2/local/lib/python2.7/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/home/ist/code/treadmill/tests/zksync_test.py", line 11, in <module>
    import tests.treadmill_test_deps  # pylint: disable=W0611
  File "/home/ist/code/treadmill/tests/treadmill_test_deps.py", line 16, in <module>
    os.path.join(PROJ_DIR, 'test_setup.py'))
IOError: [Errno 2] No such file or directory

======================================================================

It seems that there is no file named test_setup.py but it is used in every test cases.

https://github.com/Morgan-Stanley/treadmill/blame/master/tests/treadmill_test_deps.py#L16

@gaocegege
Copy link
Contributor

gaocegege commented Feb 17, 2017

And, the users have to pip install pyyaml and pip install prettytable if they want to run bin/treadmill

@gaocegege
Copy link
Contributor

Sorry, the file is in #7, I missed the PR.

@ceache ceache closed this as completed May 11, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants