missing else clause and TODO comments in statistics group by storage tests

Bug #1217688 reported by Terri Yu
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ceilometer
Fix Released
Low
Terri Yu

Bug Description

A few minor issues that were raised in the code review comments for Patch Set 10 of "Add SQLAlchemy implementation of groupby" https://review.openstack.org/#/c/41597/

1) test_group_by_with_query_filter_multiple in class StatisticsGroupByTest in tests/storage/test_storage_scenarios.py is missing an else clause in the code block where it checks values returned by get_meter_statistics(). The else clause would ensure that all possible values for 'project_id' and 'resource_id' are covered.

2) tests/storage/test_storage_scenarios.py defines tests for group by with metadata fields in class StatisticsGroupByTest, but these are not implemented. The body of the tests is "pass." A TODO comment needs to be added to each of these tests.

Terri Yu (terriyu)
description: updated
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/43993

Changed in ceilometer:
assignee: nobody → Terri Yu (terriyu)
status: New → In Progress
Terri Yu (terriyu)
summary: - missing else clause and TODO comments in storage driver tests
+ missing else clause and TODO comments in statistics group by storage
+ driver tests
summary: missing else clause and TODO comments in statistics group by storage
- driver tests
+ tests
Julien Danjou (jdanjou)
Changed in ceilometer:
importance: Undecided → Low
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ceilometer (master)

Reviewed: https://review.openstack.org/43993
Committed: http://github.com/openstack/ceilometer/commit/2e484972e1893682159458461a1eaea7a5cf48f6
Submitter: Jenkins
Branch: master

commit 2e484972e1893682159458461a1eaea7a5cf48f6
Author: Terri Yu <email address hidden>
Date: Wed Aug 28 05:38:48 2013 +0000

    Adds else and TODO in statistics storage tests

    Fixes bug #1217688

    Addresses minor issues that were raised in the code review comments
    for Patch Set 10 of "Add SQLAlchemy implementation of groupby"
    https://review.openstack.org/#/c/41597/

    The issues were in the StatisticsGroupByTest class of the storage
    driver tests.

    1) Adds else clause to test_group_by_with_query_filter_multiple

       The else clause ensures that all possible values for 'project_id'
       and 'resource_id' are covered when checking the values returned
       by get_meter_statistics().

    2) Adds TODO comments for tests that are not implemented

       The tests that have not been implemented are ones involving
       metadata fields, since group by with metadata fields has not yet
       been implemented.

    Change-Id: I55cc0cb6cc791708c9b8038787d712760f9515df

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.

Other bug subscribers

Remote bug watches

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