Merge lp://qastaging/~registry/horizon/dashboard_manager_tests into lp://qastaging/~hudson-openstack/horizon/trunk

Proposed by Mark Gius
Status: Needs review
Proposed branch: lp://qastaging/~registry/horizon/dashboard_manager_tests
Merge into: lp://qastaging/~hudson-openstack/horizon/trunk
Diff against target: 910 lines (+857/-3)
4 files modified
django-openstack/src/django_openstack/nova/ (+3/-3)
django-openstack/src/django_openstack/nova/tests/ (+1/-0)
django-openstack/src/django_openstack/nova/tests/ (+852/-0)
django-openstack/src/django_openstack/ (+1/-0)
To merge this branch: bzr merge lp://qastaging/~registry/horizon/dashboard_manager_tests
Reviewer Review Type Date Requested Status
Devin Carlen Needs Fixing
Review via email:

Description of the change

Unit tests for django_openstack.nova.manager methods.

To post a comment you must log in.
69. By Mark Gius

Merge from trunk

Revision history for this message
Mark Gius (markgius) wrote :

I had a thought about my grouping of testcases in here and the effect on mocks.

The method I used works fine for the manager tests because the test class doesn't use setUp to set anything other than the mock factory instance. But if we had setUp create mock objects:

def classA(testcase):
  def setUp(self):
    self.mox = Mox()

  def tearDown(self):

def classB(testcase):
  def setupHelper(self):
    # sets some mocks common to certain tests
  def test_something(self):
    def test_internal1():
       # some code here
    def test_internal2():
       # blah blah

If the internal test cases depend at all on the parent classes setUp mocks, then these test cases will fail, because they've unset the setUp stubs along with their internal ones.

If this "problem" is cause for a merge denial, I'll find a better way to group tests.

Revision history for this message
Devin Carlen (devcamcar) wrote :

NOVA_CLC_IP is deprecated. You can remove this line and any tests that require it. The instance graphing bits are bitrotted and we'll remove them soon. For now you can remove those tests.

907 +NOVA_CLC_IP = ''

def test_get_instance_graph(self):

review: Needs Fixing

Unmerged revisions

69. By Mark Gius

Merge from trunk

68. By Mark Gius

All manager methods tested

67. By Mark Gius

More tests. fixed one borken test

66. By Mark Gius

More tests, and a third broken test.

65. By Mark Gius

More tests implemented

64. By Mark Gius

More tests implemented

63. By Mark Gius

more tests

62. By Mark Gius

more tests implemented.

61. By Mark Gius

Test stubs and one test completed for manager

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.


People subscribed via source and target branches