File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ package api
22
33import (
44 "bytes"
5- "fmt"
65 "text/template"
76)
87
@@ -66,14 +65,3 @@ type Autoscale struct {
6665
6766// Labels can contain any user-defined key value
6867type Labels map [string ]interface {}
69-
70- func (l Labels ) String () string {
71- var buffer bytes.Buffer
72- for k , v := range l {
73- if buffer .Len () > 0 {
74- buffer .WriteString ("\n " )
75- }
76- buffer .WriteString (fmt .Sprintf ("%-16s %s" , k + ":" , v ))
77- }
78- return buffer .String ()
79- }
Original file line number Diff line number Diff line change @@ -30,17 +30,3 @@ CPU: 40%`)
3030 t .Errorf ("Expected:\n \n %s\n \n Got:\n \n %s" , expected2 , a2 .String ())
3131 }
3232}
33-
34- func TestLabelsString (t * testing.T ) {
35- data := Labels {
36- "git_repo" : "https://github.com/deis/controller-sdk-go" ,
37- "team" : "deis" ,
38- }
39-
40- expected := strings .TrimSpace (`git_repo: https://github.com/deis/controller-sdk-go
41- team: deis` )
42-
43- if strings .TrimSpace (data .String ()) != expected {
44- t .Errorf ("Expected:\n \n %s\n \n Got:\n \n %s" , expected , data .String ())
45- }
46- }
You can’t perform that action at this time.
0 commit comments