Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
C
corepost
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
nexlab
corepost
Commits
45f15f6a
Commit
45f15f6a
authored
Apr 16, 2012
by
Jacek Furmankiewicz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
issue #4: fix to unit test to remove user-agent that varies on every box
parent
f1473eb4
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
1 deletion
+1
-1
filters.feature
corepost/test/feature/filters.feature
+0
-1
filter_resource.py
corepost/test/filter_resource.py
+1
-0
No files found.
corepost/test/feature/filters.feature
View file @
45f15f6a
...
...
@@ -25,7 +25,6 @@ Feature: Filters
"accept-encoding": "gzip, deflate",
"custom-header": "Custom Header Value",
"host": "127.0.0.1:8083",
"user-agent": "Python-httplib2/0.7.2 (gzip)",
"x-wrap-input": "Input"
}
"""
...
...
corepost/test/filter_resource.py
View file @
45f15f6a
...
...
@@ -28,6 +28,7 @@ class WrapAroundFilter():
implements
(
IRequestFilter
,
IResponseFilter
)
def
filterRequest
(
self
,
request
):
del
(
request
.
received_headers
[
"user-agent"
])
# remove this for unit tests, it varies from one box to another
request
.
received_headers
[
"X-Wrap-Input"
]
=
"Input"
def
filterResponse
(
self
,
request
,
response
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment