File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,8 @@ func TestDataSourceProxy(t *testing.T) {
14
14
15
15
Convey ("When getting graphite datasource proxy" , t , func () {
16
16
ds := m.DataSource {Url : "htttp://graphite:8080" , Type : m .DS_GRAPHITE }
17
- proxy := NewReverseProxy (& ds , "/render" )
17
+ targetUrl , _ := url .Parse (ds .Url )
18
+ proxy := NewReverseProxy (& ds , "/render" , targetUrl )
18
19
19
20
requestUrl , _ := url .Parse ("http://grafana.com/sub" )
20
21
req := http.Request {URL : requestUrl }
@@ -36,7 +37,8 @@ func TestDataSourceProxy(t *testing.T) {
36
37
Password : "password" ,
37
38
}
38
39
39
- proxy := NewReverseProxy (& ds , "" )
40
+ targetUrl , _ := url .Parse (ds .Url )
41
+ proxy := NewReverseProxy (& ds , "" , targetUrl )
40
42
41
43
requestUrl , _ := url .Parse ("http://grafana.com/sub" )
42
44
req := http.Request {URL : requestUrl }
You can’t perform that action at this time.
0 commit comments