Commit Graph

4 Commits

Author SHA1 Message Date
Sean McGinnis 22efa8fd7f Use unittest.mock instead of third party mock
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.

Change-Id: I5ad2c7a44dee2e19ab2576f206c69d94126a22b1
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
Co-Authored-By: zhurong <aaronzhu1121@gmail.com>
2020-04-20 03:54:03 -07:00
zhurong 4985bfa010 Switch test runner to django default runner
nose is not actively maintained now and Django default test runner
seems to have enough features.

Horizon test setting no longer depends on nose and related stuffs.
This commit cleans up nose related dependencies.
The change was made in horizon Rocky-3,
so horizon 14.0.0.0b3 is required at least.

And murano-dashboard using unittest instead of testtools.

Co-Authored-By: Akihiro Motoki <amotoki@gmail.com>
Change-Id: I419e0e166ea88c3ab1203f35ffa00928cf94acb1
Depends-On: https://review.openstack.org/599156/
2018-10-09 02:22:08 +00:00
Felipe Monteiro 11ba34e3c6 Fixes unit tests throwing errors, related to Horizon function.
Currently, 11 unit tests are failing because Horizon
changed some of its behavior related to how pagesizes are
calculated from request objects.

This is the commit in Horizon that appears to have caused things
to break in these unit tests:
https://review.openstack.org/#/c/155939/13/horizon/utils/functions.py

This fix mocks out the function in Horizon that does the pagesize
calculation.

Change-Id: I983e83033b8eab25f79f505d2e57ef1e6b86873b
Closes-Bug: #1650029
2016-12-14 16:42:38 -05:00
Felipe Monteiro 2f670a2099 Increase unit test coverage for muranodashboard Categories Views.
Created categories sub-folder in muranodashboard.tests.unit and
added this test file under it.

implements bp: murano-unit-test-coverage

Change-Id: I5cfc09fb725ea48c7c2f97ed391bdf695657912a
2016-12-02 11:04:32 -05:00