run_tests.sh runs all tests even when one specifies a single test file

Bug #1181996 reported by Rushi Agrawal
18
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Cinder
Fix Released
Undecided
John Griffith

Bug Description

when one executes
./run_tests.sh cinder.tests.blah_test_file -N

The test runner first runs the tests from blah_test_file, and then continues with running _all_ the tests from cinder test suite

Rushi Agrawal (rushiagr)
description: updated
Changed in cinder:
status: New → Confirmed
Revision history for this message
John Griffith (john-griffith) wrote :

While we're working on moving to testr and getting this fixed you can run individual tests directly with nosetests:
    nosetests --tests ./cinder/tests/test_my_test.py

and you can use pdb by adding:
    --pdb --nocapture

Revision history for this message
John Griffith (john-griffith) wrote :

Oh.. and by the way, since run_tests.sh is just a wrapper around all of this you can also put it all together there and do:

    ./run_tests.sh --pdb --nocapture --tests ./cinder/tests/test_hds.py

Changed in cinder:
assignee: nobody → John Griffith (john-griffith)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cinder (master)

Reviewed: https://review.openstack.org/30491
Committed: http://github.com/openstack/cinder/commit/2be0b9c39c20bd3d0144abf84232f1b2043ca6e1
Submitter: Jenkins
Branch: master

commit 2be0b9c39c20bd3d0144abf84232f1b2043ca6e1
Author: John Griffith <email address hidden>
Date: Fri May 24 13:46:28 2013 -0600

    Hack run_tests.sh to work with single tests again.

    Even though we're moving to testr and this will eventually
    go away, we should maintain our ability to run and debug
    individual tests until the broader change is released.

    This just adds some text around the nosetests call
    to get us back where we were.

    Fixes bug: 1181996

    Change-Id: Id0082ca8954664679430cc602425b1fadd29151b

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