tempest failure: test_list_agent failes with MismatchError

Bug #1266954 reported by Itsuro Oda
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
neutron
Fix Released
High
shihanzhang

Bug Description

Jenkins job 'check-tempest-dsvm-neutron-pg-isolated' failed when I posted a fix.
(see. http://logs.openstack.org/34/65034/1/check/check-tempest-dsvm-neutron-pg-isolated/d3e37ea )

Failed test is as follows:
---
 FAIL: tempest.api.network.admin.test_agent_management.AgentManagementTestJSON.test_list_agent[gate,smoke]
 tempest.api.network.admin.test_agent_management.AgentManagementTestJSON.test_list_agent[gate,smoke]

 Traceback (most recent call last):
   File "tempest/api/network/admin/test_agent_management.py", line 37, in test_list_agent
     self.assertIn(self.agent, agents)
   File "/usr/local/lib/python2.7/dist-packages/testtools/testcase.py", line 330, in assertIn
     self.assertThat(haystack, Contains(needle))
   File "/usr/local/lib/python2.7/dist-packages/testtools/testcase.py", line 414, in assertThat
     raise MismatchError(matchee, matcher, mismatch, verbose)
 MismatchError: {u'binary': u'neutron-dhcp-agent', u'description': None, ... snip
---

I found the mismatch is only 'heartbeat_timestamp'.
expected: u'heartbeat_timestamp': u'2014-01-06 06:52:48.291601'
real: u'heartbeat_timestamp': u'2014-01-06 06:52:52.309330'

In test_list_agent GET API issues twice and compare results.
It is possible to differ heartbeat_timestam isn't it?

Revision history for this message
shihanzhang (shihanzhang) wrote :

I think the heartbeat_timestam should not be difffered,but the body that agent_list return includes heartbeat_timestam,so it should remove the heartbeat_timestam before using "assertIn"

Changed in neutron:
assignee: nobody → shihanzhang (shihanzhang)
Revision history for this message
yong sheng gong (gongysh) wrote :

It seem it should affect tempest only.

Revision history for this message
yong sheng gong (gongysh) wrote :

This will fix part of the check-tempest-dsvm-neutron-pg-isolated failures.

Changed in neutron:
status: New → Confirmed
importance: Undecided → High
Revision history for this message
Joe Gordon (jogo) wrote :

This hasn't been seen in two weeks, marking as resolved.

Changed in neutron:
status: Confirmed → Fix Committed
Thierry Carrez (ttx)
Changed in neutron:
milestone: none → icehouse-rc1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in neutron:
milestone: icehouse-rc1 → 2014.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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