summaryrefslogtreecommitdiff
path: root/spec/lib/gitlab/middleware
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2016-11-18 20:17:10 +0800
committerLin Jen-Shin <godfat@godfat.org>2016-11-18 20:17:10 +0800
commit9c4e0d64451bd76b829e1bb66afab892e19926da (patch)
tree7bcbfa45907119ab0039f696607fdf4e1557fb46 /spec/lib/gitlab/middleware
parent688ff26df3f288e5cd50096a01014188a5e4011b (diff)
downloadgitlab-ce-9c4e0d64451bd76b829e1bb66afab892e19926da.tar.gz
Use `Gitlab.config.gitlab.host` over `'localhost'`fix-tests-for-different-host
This would fix long standing failures running tests on my development machine, which set `Gitlab.config.gitlab.host` to another host because it's not my local computer. Now I finally cannot withstand it and decided to fix them once and for all.
Diffstat (limited to 'spec/lib/gitlab/middleware')
-rw-r--r--spec/lib/gitlab/middleware/go_spec.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/lib/gitlab/middleware/go_spec.rb b/spec/lib/gitlab/middleware/go_spec.rb
index 117a15264da..fd3769d75b5 100644
--- a/spec/lib/gitlab/middleware/go_spec.rb
+++ b/spec/lib/gitlab/middleware/go_spec.rb
@@ -22,7 +22,7 @@ describe Gitlab::Middleware::Go, lib: true do
resp = middleware.call(env)
expect(resp[0]).to eq(200)
expect(resp[1]['Content-Type']).to eq('text/html')
- expected_body = "<!DOCTYPE html><html><head><meta content='localhost/group/project git http://localhost/group/project.git' name='go-import'></head></html>\n"
+ expected_body = "<!DOCTYPE html><html><head><meta content='#{Gitlab.config.gitlab.host}/group/project git http://#{Gitlab.config.gitlab.host}/group/project.git' name='go-import'></head></html>\n"
expect(resp[2].body).to eq([expected_body])
end
end