logging outputs in test cases

Bug #1137249 reported by yong sheng gong
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Medium
yong sheng gong

Bug Description

quantum/tests/unit/services/agent_loadbalancer/agent/test_init.py:
    def test_main(self):
        with contextlib.nested(
            mock.patch.object(agent.service, 'launch'),
            mock.patch.object(agent, 'eventlet'),
            mock.patch('sys.argv'),
            mock.patch.object(agent.manager, 'LbaasAgentManager')
        ) as (mock_launch, mock_eventlet, sys_argv, mgr_cls):
            agent.main()

            self.assertTrue(mock_eventlet.monkey_patch.called)
            mock_launch.assert_called_once_with(mock.ANY)

we should mock quantum.agent.common.config.setup_logging when we have case for main

Changed in quantum:
milestone: none → grizzly-rc1
assignee: nobody → yong sheng gong (gongysh)
importance: Undecided → Medium
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to quantum (master)

Fix proposed to branch: master
Review: https://review.openstack.org/23250

Changed in quantum:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to quantum (master)

Reviewed: https://review.openstack.org/23250
Committed: http://github.com/openstack/quantum/commit/8d44479717986790c530c445026b79d6f75dadc3
Submitter: Jenkins
Branch: master

commit 8d44479717986790c530c445026b79d6f75dadc3
Author: gongysh <email address hidden>
Date: Fri Mar 1 15:36:19 2013 +0800

    mock quantum.agent.common.config.setup_logging

    Bug #1137249

    Change-Id: I7eb7ec3c0247c1ceeefc8e3f88d9cd7753c38c0c

Changed in quantum:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in quantum:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in quantum:
milestone: grizzly-rc1 → 2013.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.