Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
gpt
large_projects
gitlabhq1
Commits
41ccfc30
Commit
41ccfc30
authored
7 years ago
by
Constance Okoghenun
Browse files
Options
Download
Email Patches
Plain Diff
Fixed broken selenium proxy url
parent
c6cb3f24
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
1 deletion
+18
-1
spec/support/capybara.rb
spec/support/capybara.rb
+18
-1
No files found.
spec/support/capybara.rb
View file @
41ccfc30
...
...
@@ -82,19 +82,36 @@ RSpec.configure do |config|
end
puts
Gitlab
::
Utils
.
to_boolean
(
ENV
[
'GITLAB_SELENIUM_SERVER'
])
puts
"====================================================="
if
Gitlab
::
Utils
.
to_boolean
(
ENV
[
'GITLAB_SELENIUM_SERVER'
])
test_path
=
self
.
inspect
.
to_s
.
sub
(
"("
,
""
).
sub
(
")>"
,
""
).
split
(
"
\"
"
)
puts
test_path
puts
"Hello World"
uri
=
URI
::
join
(
"
#{
ENV
[
'SELENIUM_REMOTE_URL'
]
}
"
,
"session/
#{
session
.
driver
.
browser
.
capabilities
[
'webdriver.remote.sessionid'
]
}
/gitlab-meta"
)
uri
=
URI
::
join
(
"
#{
ENV
[
'SELENIUM_REMOTE_URL'
]
}
/
"
,
"session/
#{
session
.
driver
.
browser
.
capabilities
[
'webdriver.remote.sessionid'
]
}
/gitlab-meta"
)
req
=
Net
::
HTTP
::
Post
.
new
(
uri
,
'Content-Type'
=>
'application/json'
)
req
.
body
=
{
description:
test_path
[
1
],
location:
test_path
[
2
],
}.
to_json
puts
uri
;
puts
"====================================================="
res
=
Net
::
HTTP
.
start
(
uri
.
hostname
,
uri
.
port
)
do
|
http
|
http
.
request
(
req
)
end
case
res
when
Net
::
HTTPSuccess
,
Net
::
HTTPRedirection
puts
res
.
inspect
puts
" Net::HTTPSuccess, Net::HTTPRedirection ====================================================="
else
puts
res
.
inspect
puts
" else ====================================================="
end
end
end
...
...
This diff is collapsed.
Click to expand it.
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