Since tests run in parallel, cfg.CONF state can be not that we expect

Bug #1211239 reported by Mehdi Abaakouk
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Ceilometer
Fix Released
Critical
Julien Danjou

Bug Description

Hi,

After investigation of why this merge failed:
http://logs.openstack.org/10/39510/4/check/gate-ceilometer-python27/ed09521/console.html

I have discovered that tests randomly failed when mongo < 2.2 is installed
$ for i in $(seq 0 20) ; do tox -epy27 >/dev/null 2>&1 && echo -n . || echo -n X ; done
....X..XXX..X..X.X.X.

After investigation, all tests in tests.collector.dispatcher.test_db assume that the cfg.CONF.database.connection is the default one (ie: a sqlite databases) or sometimes it is a other backends.

because when a test is skipped, the cfg.CONF is not reset

Cheers

Mehdi Abaakouk (sileht)
Changed in ceilometer:
assignee: nobody → Mehdi Abaakouk (sileht)
Mehdi Abaakouk (sileht)
Changed in ceilometer:
status: New → In Progress
importance: Undecided → Medium
importance: Medium → High
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ceilometer (master)

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

Julien Danjou (jdanjou)
Changed in ceilometer:
importance: High → Critical
Changed in ceilometer:
assignee: Mehdi Abaakouk (sileht) → Julien Danjou (jdanjou)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ceilometer (master)

Reviewed: https://review.openstack.org/41422
Committed: http://github.com/openstack/ceilometer/commit/cc803b10f65fa71336be3c4184726a97d2713d8c
Submitter: Jenkins
Branch: master

commit cc803b10f65fa71336be3c4184726a97d2713d8c
Author: Mehdi Abaakouk <email address hidden>
Date: Mon Aug 12 14:31:55 2013 +0200

    Use new olso fixture in CM tests

    Before this change mox and cfg.CONF wasn't cleaned up correctly if
    skipTest is called, because when skipTest is used teardown is not
    called.

    Now we use the oslo fixtures to setup oslo.config and mox to ensure the
    cleanup is done between each tests.

    Fixes bug #1211239

    Change-Id: I5075c99106742859f0705b765f8ed4aa9be494d7

Changed in ceilometer:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in ceilometer:
milestone: none → havana-3
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in ceilometer:
milestone: havana-3 → 2013.2
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.