summaryrefslogtreecommitdiff
path: root/keystoneclient/tests/unit/utils.py
Commit message (Collapse)AuthorAgeFilesLines
* Deprecations fixture support calling deprecated functionBrant Knudson2015-07-241-1/+1
| | | | | | | | Sometimes a test is expected to call deprecated function, such as when testing that deprecated function still works. Now the test can tell the Deprecations fixture that it's calling deprecated function. Change-Id: Ic7486b74f681989eb5110dfeaf8dae0e5d7ae50e
* Merge "Unit tests catch deprecated function usage"Jenkins2015-07-231-0/+4
|\
| * Unit tests catch deprecated function usageBrant Knudson2015-06-301-0/+4
| | | | | | | | | | | | | | | | | | | | Rather than continue to call deprecated functions without knowing it, have the unit tests fail when deprecated function is used. This will ensure that code isn't added that calls deprecated functions. Change-Id: If9f58e30a08a88778e4ae3fc01399ad90997e812
* | Remove unused time_patcherBoris Bobrov2015-07-231-5/+0
|/ | | | | | There is no reason to patch time now, tests succeed without it Change-Id: I3cf3017b5f86bae35276037c60cfec8dc3be20ae
* Stop using tearDownBrant Knudson2015-06-131-7/+3
| | | | | | | | tearDown doesn't get called when there's an exception in setUp, which can cause issues with test stability and isolation, so better to avoid it. Change-Id: I5ca2d84bcf82f4c88af26b4c582b0f23264a959c
* Use mock rather than moxBrant Knudson2015-06-131-4/+0
| | | | | | | Switch to mock rather than mox. We should pick one or the other mocking library, and mock is preferred. Change-Id: I86ad9638da2f53189fbaea3fd9476356eb0c7ff5
* Merge "Iterate over copy of sys.modules keys in Python2/3"Jenkins2015-06-111-1/+1
|\
| * Iterate over copy of sys.modules keys in Python2/3Corey Bryant2015-06-091-1/+1
| | | | | | | | | | | | | | | | | | Iterate over a copy of sys.modules keys in both Python 2.x and Python 3.x. In Python 3.x, keys() is not a copy, and therefore items can't be popped from it while iterating. Change-Id: I98c3d7695bbfe3a6a4f23990af45a07dc147f22f Closes-Bug: #1463503
* | Use random strings for test fixturesBrant Knudson2015-06-081-7/+7
|/ | | | | | | Tests should use a random string so that we don't mistakenly use the wrong string and not test what we think we're testing. Change-Id: Ied0672db78a1e1cf2d390020cc5a49d0203683be
* Revert "Remove unused fixtures"Brant Knudson2015-05-211-0/+47
| | | | | | | | Repropose this This reverts commit e7853b8909358a78b8ae86c075ee234467a0d82f. Change-Id: I7b21bb139ccf7379d6f1b26f1ecddaa43767a334
* Remove unused fixturesVictor Stinner2015-05-121-47/+0
| | | | | | DisableModuleFixture and NoModuleFinder fixtures are no more used. Change-Id: I55a5e106b5d4d618918ee21b33afd0154e22f6b7
* Rename requests mock object in testingJamie Lennox2015-03-181-6/+6
| | | | | | | | | | | | | | It has been mentioned a number of times that the self.requests naming for the requests_mock object is confusing between whether you are actually sending a request or are mocking a request. Rename all entries of the requests object to requests_mock. This cleans up a couple of entries where the older register_uri format was being used in favour of using the HTTP method as the requests_mock method. Change-Id: I315085b4088130b510f9dbd696011d983598372c
* Move tests to the unit subdirectoryJamie Lennox2015-02-111-0/+209
Move all the existing tests to the unit/ subdirectory. This gives us some room to add a functional/ directory later with other tests. Change-Id: I0fb8d5b628eb8ee1f35f05f42d0c0ac9f285e8c3 Implements: functional-testing