TestContainer.test_sync_first_loop will fail when there is an process binding on 80
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Object Storage (swift) |
Fix Released
|
Low
|
Peter Portante |
Bug Description
I have apache binding (with horizon fwiw) on port 80 listening on everything including localhost, and the test would fail when it's launched since it actually try to connect on that port.
stack@devstack:
test_container_
-------
Ran 1 test in 0.005s
OK
stack@devstack:
* Starting web server apache2 [ OK ]
stack@devstack:
test_container_
=======
FAIL: test_container_
-------
Traceback (most recent call last):
File "/opt/stack/
self.
AssertionError: 2 != 3
'2 != 3' = '%s != %s' % (safe_repr(2), safe_repr(3))
'2 != 3' = self._formatMes
>> raise self.failureExc
-------
swiftclient: DEBUG: REQ: curl -i http://
swiftclient: DEBUG: RESP STATUS: 404
swiftclient: DEBUG: RESP BODY:
<!DOCTYPE html>
<html lang="en">
[.....]
Changed in swift: | |
assignee: | nobody → Chmouel Boudjnah (chmouel) |
Changed in swift: | |
importance: | Undecided → Low |
Changed in swift: | |
status: | New → In Progress |
Changed in swift: | |
assignee: | Chmouel Boudjnah (chmouel) → Peter Portante (peter-a-portante) |
Changed in swift: | |
milestone: | none → 1.10.0-rc1 |
status: | Fix Committed → Fix Released |
Changed in swift: | |
milestone: | 1.10.0-rc1 → 1.10.0 |
Reviewed: https:/ /review. openstack. org/40401 github. com/openstack/ swift/commit/ d3bd30da4191e57 6f4e7b78498979f fc8892eeb5
Committed: http://
Submitter: Jenkins
Branch: master
commit d3bd30da4191e57 6f4e7b78498979f fc8892eeb5
Author: Chmouel Boudjnah <email address hidden>
Date: Tue Aug 6 14:15:48 2013 +0200
Fix sync test when localhost on port 80 is binded
- When localhost:80 was binding the tests was trying to connect into it.
- To test you can simply run sudo python -m SimpleHTTPServer 80 which
should show :
1. 0.0.127. in-addr. arpa - - [06/Aug/2013 14:10:42] code 501, message Unsupported method ('DELETE') 0.0.127. in-addr. arpa - - [06/Aug/2013 14:10:42] "DELETE /a/c/o HTTP/1.1" 501 -
1.
(the test was passing since 501 would raise ClientException).
mock delete_object in the fourth test to fix that
- Refactor the code to use mock.patch as well.
Closes-Bug: 1208802 f51cf5883fcfc0f e0f0adaeff6
Change-Id: I5ddd4ac3a97879