summaryrefslogtreecommitdiff
path: root/openstackclient/tests/functional/object
Commit message (Collapse)AuthorAgeFilesLines
* Blacken openstackclient.objectStephen Finucane2023-05-102-16/+26
| | | | | | | | | | Black used with the '-l 79 -S' flags. A future change will ignore this commit in git-blame history by adding a 'git-blame-ignore-revs' file. Change-Id: I6658e76d7d1f93149f24fcab28d593195b37779f Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* Fix functional tests for py3Eric Fried2019-10-311-1/+1
| | | | | | | | | | | | | | | | Fix various things so the functional tests will work under python3: - A hashlib.md5() can only be update()d with an encoded string in py3. - There's no dict.iteritems(), change to dict.items() (which is already an iterator). - Open temp files with 'w+' mode rather than the default 'w+b' (as an alternative to encoding all the write and expected-read payloads as bytes). - (This is a weird one) Explicitly raise SkipTest from unittest (rather than unittest2, which is where cls.skipException landed). Not sure why this is busted, but this moves the ball. Change-Id: Ic9b2b47848a600e87a3674289ae7ae8c3e091fee
* Fix service discovery in functional testsGlenn Van de Water2019-03-131-1/+1
| | | | | | | | | | | | | | | | | | | | | If a required service is not enabled then we skip the test. The discovery is done by tests/functional/base.py:is_service_enabled but this method is broken, credentials are not passed to the 'openstack service show' command so every call will fail and every test that relies on it will be skipped. This commit fixed that method and the issues that popped up when re-enabling tests. Network segment range: - issue where we assumed network-segment-range extension is always present - issue where we compare integers and string representations of numbers Subnet: - issue where we try to deepcopy an uncopyable object in UnsetSubnet Change-Id: Id3cc907c1ed2a25b49cf6f4a7233e0401a02383a Story: 2005169 Task: 29908
* Clean up W503 and E402 pep8 errorsSean McGinnis2018-04-151-16/+16
| | | | | | | | | | | | pycodestyle 2.40 and later enforce these rules that were not previously enforced. Rather than just skipping them, this cleans up the trivial instances of these violations. This does also include some other updates that were not triggering errors in an attempt to keep some of the style consistent. Change-Id: Id7c0a6b8f1f835e69d844b000e3ed751852ada63 Closes-bug: #1762803
* Skip object-store functional tests when Swift is not availableDean Troyer2017-07-263-11/+48
| | | | | | | | Specifically, in the py3 jobs Swift is not (yet) properly starting as a py2 service, so we disabled swift in those OSC jobs and need to skip the object-store functional tests in that case. Change-Id: I073551c41b7636f04b3ee97dc6fe69630e207b67
* Clean up the changes of os.environ in functional testsRui Chen2017-07-201-2/+6
| | | | | | | | | | | | Use fixtures to restore the API version changes of os.environ in each functional tests, aims to avoid the following test cases failing in unexpected context. And make sure setUpClass/tearDownClass call super class's corresponding methods first. Change-Id: Ie248fe9d3a9e25f1b076c9f2c363200f29a83817 Closes-Bug: #1696080
* Allow objects to be streamed to stdoutHonza Pokorny2017-07-051-0/+4
| | | | Change-Id: Icd8de6b2122fe77926d93da9bda08f56c3672a7a
* move all functional tests to tests moduleSteve Martinelli2016-09-094-0/+122
functional tests should be grouped with other tests (unit and integration tests). as part of this commit the "common" module was renamed to just "base", this was done for simplicity. the post_test_hook.sh file was also copied to the functional module since it should live there. a separate change to the infra repo will be made to call the new location, once that is merged we can remove the old one (a new change will also be posted for that) Needed-By: I49d54f009021d65c1ae49faf6b3f0a7acdadd7b3 Change-Id: Ie8c334f6223373b8e06df8bd8466500d2a2c8ede