This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 693978 - test_immediate_method unit test failing with 'TypeError: int argument required'
test_immediate_method unit test failing with 'TypeError: int argument required'
Status: CLOSED NOTABUG
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: qpid-qmf (Show other bugs)
Development
Unspecified Linux
medium Severity medium
: 2.2
: ---
Assigned To: messaging-bugs
MRG Quality Engineering
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2011-04-06 03:23 EDT by Frantisek Reznicek
Modified: 2015-11-15 20:13 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-02-21 09:14:03 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Frantisek Reznicek 2011-04-06 03:23:06 EDT
Description of problem:

Python unit test from qpid-tests package constantly failing with following trace:
qpid_tests.broker_0_10.management.ManagementTest.test_immediate_method .. fail
Error during test:
  Traceback (most recent call last):
    File "/usr/bin/qpid-python-test", line 311, in run
      phase()
    File "/usr/lib/python2.4/site-packages/qpid_tests/broker_0_10/management.py", line 457, in test_immediate_method
      url = "%s://%s:%d" % (self.broker.scheme or "amqp", self.broker.host, self.broker.port)
  TypeError: int argument required

This seems to be an test error.
Seen on RHEL4.9 / 5.6 / 6.1 i386 / x86_64.

Version-Release number of selected component (if applicable):

python-qpid-0.10-1.el5.noarch
python-qpid-qmf-0.10-2.el5.i386
qpid-cpp-client-0.10-1.el5.i386
qpid-cpp-client-devel-0.10-1.el5.i386
qpid-cpp-client-devel-docs-0.10-1.el5.i386
qpid-cpp-client-rdma-0.10-1.el5.i386
qpid-cpp-client-ssl-0.10-1.el5.i386
qpid-cpp-mrg-debuginfo-0.10-1.el5.i386
qpid-cpp-server-0.10-1.el5.i386
qpid-cpp-server-cluster-0.10-1.el5.i386
qpid-cpp-server-devel-0.10-1.el5.i386
qpid-cpp-server-rdma-0.10-1.el5.i386
qpid-cpp-server-ssl-0.10-1.el5.i386
qpid-cpp-server-store-0.10-1.el5.i386
qpid-cpp-server-xml-0.10-1.el5.i386
qpid-dotnet-0.4.738274-2.el5.i386
qpid-java-client-0.10-1.el5.noarch
qpid-java-common-0.10-1.el5.noarch
qpid-java-example-0.10-1.el5.noarch
qpid-qmf-0.10-2.el5.i386
qpid-qmf-debuginfo-0.10-2.el5.i386
qpid-qmf-devel-0.10-2.el5.i386
qpid-tests-0.10-1.el5.noarch
qpid-tools-0.10-1.el5.noarch
rh-qpid-cpp-tests-0.10-1.el5.i386
ruby-qpid-qmf-0.10-2.el5.i386

How reproducible:
100%

Steps to Reproduce:
1. install above packages
2. start broker
3. launch function utest (see definition below)
  
Actual results:
qpid_tests.broker_0_10.management.ManagementTest.test_immediate_method unit test fails.

Expected results:
qpid_tests.broker_0_10.management.ManagementTest.test_immediate_method should pass.

Additional info:

repro bash function
function utest ()
{
  local log_fn="./units.log"
  local err_cnt_max=10
  local err_cnt=0
  local i=0
  
  rm -f ${log_fn}
  
  while true; do
    ecode=
    qpid-python-test 'qpid.tests.*' >> ${log_fn} 2>&1
    ecode=$?
    qpid-python-test -m qpid_tests 'qpid_tests.*' >> ${log_fn} 2>&1
    ecode="${ecode}$?"
    
    [[ "${ecode}" =~ "^[0]+$" ]] || let "err_cnt++"
    
    echo "run${i} --------------------------------------ecode:${ecode}|err_cnt:${err_cnt}"
  
    [ "${err_cnt}" -gt "${err_cnt_max}" ] && break
  done
  
  echo ".done, err_cnt:${err_cnt}, dur: ${SECONDS}"
}
Comment 1 Frantisek Reznicek 2012-02-20 10:55:30 EST
Still failing (qpid-tests-0.14-1.el5/6).

qpid_tests.broker_0_10.management.ManagementTest.test_immediate_method .. fail
Error during test:
  Traceback (most recent call last):
    File "/usr/bin/qpid-python-test", line 311, in run
--
    File "/usr/lib/python2.4/site-packages/qpid_tests/broker_0_10/management.py", line 457, in test_immediate_method
      url = "%s://%s:%d" % (self.broker.scheme or "amqp", self.broker.host, self.broker.port)
  TypeError: int argument required
Comment 2 Frantisek Reznicek 2012-02-21 09:14:03 EST
Test itself is correct as running with additional broker specification solves the problem:

-qpid-python-test -m qpid_tests 'qpid_tests.*'
+qpid-python-test --broker localhost:5672 -m qpid_tests 'qpid_tests.*'

Some tests rely on host and port specification, some use default broker url, it is required to explicitly specify broker url using --broker switch.

An improvement to qpid-python-test tool tracked as bug 795777.

-> CLOSED / NOT-A-BUG

Note You need to log in before you can comment on or make changes to this bug.