Unable to read test.conf while executing unit test

Bug #1543416 reported by janonymous
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Object Storage (swift)
In Progress
Undecided
janonymous

Bug Description

Problem:
root@jk:# tox -e py27
py27 create: /home/jk/Desktop/swift_code/swift_j/swift/.tox/py27
py27 installdeps: -r/home/jk/Desktop/swift_code/swift_j/swift/requirements.txt, -r/home/jk/Desktop/swift_code/swift_j/swift/test-requirements.txt
py27 develop-inst: /home/jk/Desktop/swift_code/swift_j/swift
py27 installed: appdirs==1.4.0,Babel==2.2.0,bandit==0.17.3,cffi==1.5.0,coverage==4.0.3,debtcollector==1.2.0,dnspython==1.12.0,docutils==0.12,eventlet==0.18.1,extras==0.0.3,fixtures==1.4.0,flake8==2.2.4,funcsigs==0.4,futures==3.0.4,gitdb==0.6.4,GitPython==1.0.1,greenlet==0.4.9,hacking==0.10.2,iso8601==0.1.11,Jinja2==2.8,keystoneauth1==2.2.0,linecache2==1.0.0,MarkupSafe==0.23,mccabe==0.2.1,mock==1.3.0,monotonic==0.6,msgpack-python==0.4.7,netaddr==0.7.18,netifaces==0.10.4,nose==1.3.7,nosehtmloutput==0.0.5,nosexcover==1.0.10,os-testr==0.6.0,oslo.config==3.5.0,oslo.i18n==3.2.0,oslo.serialization==2.2.0,oslo.utils==3.4.0,oslosphinx==4.2.0,PasteDeploy==1.5.2,pbr==1.8.1,pep8==1.5.7,prettytable==0.7.2,pycparser==2.14,PyECLib==1.2.0,pyflakes==0.8.1,Pygments==2.1,pyrsistent==0.11.12,python-keystoneclient==2.1.2,python-mimeparse==1.5.1,python-subunit==1.2.0,python-swiftclient==2.7.0,pytz==2015.7,PyYAML==3.11,requests==2.9.1,six==1.10.0,smmap==0.9.0,Sphinx==1.1.3,stevedore==1.10.0,-e git+https://git.openstack.org/openstack/swift@87fc21c7cfcce2a3e23a84fddcfd1309cd884716#egg=swift-master,testrepository==0.0.20,testtools==2.0.0,traceback2==1.4.0,unittest2==1.1.0,wheel==0.24.0,wrapt==1.10.6,xattr==0.7.8
py27 runtests: PYTHONHASHSEED='365979862'
py27 runtests: commands[0] | nosetests test/unit
Unable to read test config /etc/swift/test.conf - file not found

Solution:
1) We could make a dummy directory before starting the tests
2) Remove the path which is being checked i.e /etc/swift/test.conf which is of no use in current scenario also, as the path could be fetched from env variables also.

Code:
test/unit/__init__.py --> from test import get_config --> from swift.common.utils import readconf

janonymous (janonymous)
Changed in swift:
assignee: nobody → janonymous (janonymous)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to swift (master)

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

Changed in swift:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on swift (master)

Change abandoned by Jaivish Kothari(janonymous) (<email address hidden>) on branch: master
Review: https://review.openstack.org/314041
Reason: Abandoning the change to test failure causes.

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.