[ostf] Invalid test definition parser

Bug #1434170 reported by Anastasia Kuznetsova
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Released
Medium
Anastasia Kuznetsova

Bug Description

If we take a look at get_description() method in the fuel-ostf/fuel_plugin/ostf_adapter/nose_plugin/nose_utils.py file, than we can see that there are 3 key items in the test definition: Deployment tags, Available since release and Duration and we need to get their values (if they are presented ).

But for example following test description will be wrong parsed:

"""Test name
      Steps:
        1. ...
         ...
        n. ...
      Available since release: 2014.2-6.1
      Duration: 10 s
"""
because 'Available since release' goes before 'Duration' and during parsing firstly _process_docstring will be called for it. As a result docstring will be updated:

docstring = docstring[:pattern_matcher.start()]

it returns new docstring that will be cutted, so info about 'Duration' will be lost.

description: updated
Changed in fuel:
assignee: nobody → Anastasia Kuznetsova (akuznetsova)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-ostf (master)

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

Changed in fuel:
status: New → In Progress
Revision history for this message
Artem Roma (aroma-x) wrote :

I think the roots of the issue are lying in poor design of logic which provides additional service info for health-check tests. The way it is done now (parsing attributes in hardcoded docstring) is not flexible and error prone. So my suggestion is to create new bug (or feature request?) and incorporate this one into it.

Changed in fuel:
milestone: none → 6.1
importance: Undecided → Medium
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-ostf (master)

Reviewed: https://review.openstack.org/165915
Committed: https://git.openstack.org/cgit/stackforge/fuel-ostf/commit/?id=b439a21b0c08a14f5fa42d477769525efba66463
Submitter: Jenkins
Branch: master

commit b439a21b0c08a14f5fa42d477769525efba66463
Author: Anastasia Kuznetsova <email address hidden>
Date: Thu Mar 19 19:38:25 2015 +0400

    Fix bug with wrong test description prosessing

    After _process_docstring will be called for some item,
    as a result docstring will be updated and it returns new docstring
    that will be cutted, so info about next items will be lost.

    Closes-Bug: #1434170
    Change-Id: Iad13706855b476eac37157e88a1d92a864b10e9e

Changed in fuel:
status: In Progress → Fix Committed
Revision history for this message
Yaroslav Lobankov (ylobankov) wrote :

Verified on

VERSION:
  feature_groups:
    - mirantis
  production: "docker"
  release: "6.1"
  openstack_version: "2014.2.2-6.1"
  api: "1.0"
  build_number: "432"
  build_id: "2015-05-18_03-43-53"
  nailgun_sha: "076566b5df37f681c3fd5b139c966d680d81e0a5"
  python-fuelclient_sha: "38765563e1a7f14f45201fd47cf507393ff5d673"
  astute_sha: "cb655a9a9ad26848bcd9d9ace91857b6f4a0ec15"
  fuel-library_sha: "1621cb350af744f497c35f2b3bb889c2041465d8"
  fuel-ostf_sha: "9ce1800749081780b8b2a4a7eab6586583ffaf33"
  fuelmain_sha: "0e970647a83d9a7d336c4cc253606d4dd0d59a60"

Changed in fuel:
status: Fix Committed → Fix Released
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.