-
Notifications
You must be signed in to change notification settings - Fork 94
Running Ceph S3 Tests
kellymclaughlin edited this page Mar 6, 2013
·
5 revisions
- Clone the s3-tests repo
- Install pip:
sudo easy_install pip
- Install virtualenv:
sudo pip install virtualenv
- Install virtualenvwrapper:
sudo pip install virtualenvwrapper
- mkdir ~/.virtualenvs
- virtualenv --no-site-packages --distribute virtualenv
- ./virtualenv/bin/pip install --upgrade pip
- ./virtualenv/bin/pip install -r requirements.txt
- ./virtualenv/bin/python setup.py develop --allow-hosts None
- Setup and start Riak, Riak CS, and stanchion.
- Create two user accounts for testing.
- Create config file using the following template:
[DEFAULT] ## this section is just used as default for all the "s3 *" ## sections, you can place these variables also directly there ## replace with e.g. "localhost" to run against local software host = kellycs.net ## uncomment the port to use something other than 80 port = 8080 ## say "no" to disable TLS is_secure = no [fixtures] ## all the buckets created will start with this prefix; ## {random} will be filled with random characters to pad ## the prefix to 30 characters long, and avoid collisions bucket prefix = cs-s3-tests-{random}- [s3 main] ## the tests assume two accounts are defined, "main" and "alt". ## user_id is a 64-character hexstring user_id = 20ff1aedc2a76934db8a51f888b5874185dbe5533827fa5579043b5fbd3e7e18 ## display name typically looks more like a unix login, "jdoe" etc display_name = test1 ## replace these with your access keys access_key = _IYKHJDQKJFFESDCCDNL secret_key = X8rqB5mlPtpcMuzL1BRWIqdM20kiCx4cD_6xlw== [s3 alt] ## another user account, used for ACL-related tests user_id = dffd7d507b096a0a3f24269fca4aca24deec628560c02c65c98273610c4bde64 display_name = test2 ## the "alt" user needs to have email set, too email = test2@test.com access_key = 3GI6PK5IRFZPE4HZBSZF secret_key = JX85QTKSbMeghN6QxqkF8ZnIQCONGDp_H9L5Qg==
- Run some tests:
- To run all of the tests:
S3TEST_CONF=*your.conf* ./virtualenv/bin/nosetests
- To run the functional tests:
S3TEST_CONF=*your.conf* ./virtualenv/bin/nosetests s3tests.functional.test_s3
- To run a specific test:
S3TEST_CONF=s3-tests.conf ./virtualenv/bin/nosetests --tests=s3tests.functional.test_s3:test_bucket_acl_xml_write
- To run all of the tests: