summaryrefslogtreecommitdiff
path: root/tests/test_shell.py
Commit message (Collapse)AuthorAgeFilesLines
* Fix the ordering of assertEqual argumentsLouis Taylor2014-09-191-8/+8
| | | | | | | | This keeps testtools happy, since it expects the argument ordering to be (expected, actual). Change-Id: I95b41ad7645700ce23b46c7a5700e79008ed08be Closes-bug: #1277104
* Support for Metadata Definitions Catalog API0.14.0Pawel Koniszewski2014-09-031-25/+38
| | | | | | | | | | | | | | | API calls and shell commands added in this patch: - CRUD for metadefs namespaces; - CRUD for metadefs objects; - CRUD for metadefs properites; - CRD for metadefs resource types and resource type associations. Change-Id: I6d15f749038e8fd24fc651f0b314df5be7c673ef Implements: blueprint metadata-schema-catalog-support Co-Authored-By: Facundo Maldonado <facundo.n.maldonado@intel.com> Co-Authored-By: Michal Dulko <michal.dulko@intel.com> Co-Authored-By: Lakshmi N Sampath <lakshmi.sampath@hp.com> Co-Authored-By: Pawel Koniszewski <pawel.koniszewski@intel.com>
* Remove deprecated commands from shellCindy Pallares2014-08-121-11/+0
| | | | | | | | | | Remove all deprecated commands from the shell since they are no longer used and to keep the command line menu from looking cluttered. Closes-bug: #1314218 Change-Id: I66e82872988e3835e4f290f48dfc80538271426c
* Merge "Add support for Keystone v3"Jenkins2014-08-071-10/+207
|\
| * Add support for Keystone v3Bob Thyne2014-08-051-10/+207
| | | | | | | | | | | | | | | | | | This enables glanceclient to authenticate using Keystone v3 API and includes the addition of several new CLI arguments. DocImpact Change-Id: I863ba08d312363dc1ce4fc7822fb21ef53df1a4f
* | Replace old httpclient with requestsAmalaBasha2014-07-101-16/+9
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | This review implements blueprint python-request and replaces the old http client implementation in favor of a new one based on python-requests. Major changes: * raw_request and json_request removed since everything is now being handled by the same method "_request" * New methods that match HTTP's methods were added: - get - put - post - head - patch - delete * Content-Type is now being "inferred" based on the data being sent: - if it is file-like object it chunks the request - if it is a python type not instance of basestring then it'll try to serialize it to json - Every other case will keep the incoming content-type and will send the data as is. * Glanceclient's HTTPSConnection implementation will be used if no-compression flag is set to True. Co-Author: Flavio Percoco<flaper87@gmail.com> Change-Id: I09f70eee3e2777f52ce040296015d41649c2586a
* Python 3: do not use __builtin__Cyril Roelandt2014-03-071-3/+3
| | | | | | | Use six.moves.builtins instead, this works with both Python 2 and 3. Change-Id: I17cdf651edbf7907e2b8b3d6aec9ace8a76b0110 Closes-Bug: 1289107
* Merge "test_shell: remove a deprecated keyword argument"Jenkins2014-03-041-1/+0
|\
| * test_shell: remove a deprecated keyword argumentCyril Roelandt2014-02-191-1/+0
| | | | | | | | | | | | | | | | The 'version' keyword argument of argparse.ArgumentParser is deprecated. It was set to 'None' anyway, so just remove it. Closes-Bug: #1281856 Change-Id: I6e5af0d90e9b1e7a6a60d5183c13299101148442
* | Replace file with open, which is Python 3 compatibleAlex Gaynor2014-02-131-10/+10
|/ | | | Change-Id: I471ae9b372f88a508d4654b1a18c6da90397a828
* Merge "Replace file.write and os.path.exists by mock"Jenkins2014-01-221-52/+39
|\
| * Replace file.write and os.path.exists by mockAndrey Kurilin2014-01-101-52/+39
| | | | | | | | | | | | | | | | | | | | | | | | During the test files may be lost in the temporary directory. Therefore, it would be nice if we reduce dependence of temporary directory. This patch replace buildin method file.write by mock in ShellCacheSchemaTest. Also we need to replace method os.path.exists by mock to correct all checks. Fixes bug: #1267515 Change-Id: I3faca27348e15b28619e49f11d0d6cff5a9e2906
* | Remove vim headerNoboru arai2014-01-141-1/+0
|/ | | | | | | | | | | No need to set tabstop tons of times, this can be set in your vimrc file instead. More disucssion: http://openstack.10931.n7.nabble.com/Remove-vim-modelines-td21780.html Change-Id: I2b37758f9dbb2cad6457a879d4ed7ff0aa69ef8e Partial-Bug: #1229324
* Merge "change assertEquals to assertEqual"Jenkins2013-11-151-2/+2
|\
| * change assertEquals to assertEqualChristian Berendt2013-10-241-2/+2
| | | | | | | | | | | | | | According to http://docs.python.org/2/library/unittest.html assertEquals is a deprecated alias of assertEqual. Change-Id: I22f4702f41537c05684dfacb3f305627b36849c5
* | Merge "Replace OpenStack LLC with OpenStack Foundation"Jenkins2013-11-151-1/+1
|\ \ | |/ |/|
| * Replace OpenStack LLC with OpenStack FoundationZhiQiang Fan2013-09-201-1/+1
| | | | | | | | | | Change-Id: I38dcbcf1a6c8efe540fcf5f29e782cb3826e583d Fixes-Bug: #1214176
* | Fix misused assertTrue in unit testsChang Bo Guo2013-10-081-1/+3
| | | | | | | | | | | | | | | | | | Refactored unit tests to use assertEqual instead of assertTrue where needed. Closes-Bug: #1226374 Change-Id: I5f3b582e19f3461a04b5df05960095779ec8aa1a
* | Add CLI for V2 image create, update, and uploadeddie-sheffield2013-10-021-0/+107
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Provides command line support for image-create, image-update, and image-upload using the Glance V2 API. This includes building help text for create and update based on the image jsonschema as fetched from the server. Also fixes bug caused by default warlock patch generation not matching what Glance expects when updating a core property which had not originally been set when the image was created. Related to bp glance-client-v2 Change-Id: I841f9e3d05802f4b794cb6f4849abe03ff0324d9
* | Support glance client can get ipv6 image url correctlyDazhao2013-09-061-0/+11
|/ | | | | | | | | | This patch is for fix bug 1208784. In openstack ipv6 environment, if the os image url is not provided, need use the provided host to generate literal ipv6 image url. Fixes bug 1208784 Change-Id: Icb71241a639db02d079348f086bd7bd5f0412609
* Start using Pyflakes and HackingDirk Mueller2013-06-221-2/+0
| | | | | | | | | | Instead of globally ignoring pyflakes and hacking warnings, only blacklist those that trigger very frequently so far, in order to clean them up in followup commits. Fix and start gating on the rest already. Change-Id: Ied7c7250061e3bf379e8286e8ce3b9e4af817faf
* Add test for glanceclient shellsTatyana Leontovich2013-05-171-0/+84
Add unittests for the following modules: * glanceclient.shell * glanceclient.v1.shell * glanceclient.v1.legacy_shell * glanceclient.v2.shell Also add mock library to the tools/test-requires Implements: blueprint glanceclient-shells-unittests Change-Id: I5ec527c5efff3726932d234d7c67e08149643f89