@@ -18,9 +18,10 @@ var _ = Describe("Types", func() {
1818 Ω (tools ).Should (BeEmpty ())
1919 })
2020 It ("should return an a sorted slice" , func () {
21- t1 := & types.Tool {Name : "xyz" }
22- t2 := & types.Tool {Name : "abc" }
23- tb .Tools = map [string ]* types.Tool {t1 .Name : t1 , t2 .Name : t2 , "foo" : {}}
21+ t1 := & types.Tool {Name : "xyz" , Github : "foo" }
22+ t2 := & types.Tool {Name : "abc" , Google : "bar" }
23+ t3 := & types.Tool {Name : "no-source" }
24+ tb .Tools = map [string ]* types.Tool {t1 .Name : t1 , t2 .Name : t2 , t3 .Name : t3 , "foo" : {DownloadURL : "url" }}
2425 tools := tb .GetTools ()
2526 Ω (tools ).Should (HaveLen (3 ))
2627 Ω (tools [0 ].Name ).Should (Equal ("abc" ))
@@ -34,9 +35,9 @@ var _ = Describe("Types", func() {
3435 Ω (versions .Versions ).Should (BeEmpty ())
3536 })
3637 It ("should return an a sorted slice" , func () {
37- t1 := & types.Tool {Name : "xyz" , CouldNotBeFound : true }
38- t2 := & types.Tool {Name : "abc" , Version : "v1.0.0" }
39- tb .Tools = map [string ]* types.Tool {t1 .Name : t1 , t2 .Name : t2 , "foo" : {Version : "v1.2.3" }}
38+ t1 := & types.Tool {Name : "xyz" , CouldNotBeFound : true , Github : "foo" }
39+ t2 := & types.Tool {Name : "abc" , Version : "v1.0.0" , Github : "foo" }
40+ tb .Tools = map [string ]* types.Tool {t1 .Name : t1 , t2 .Name : t2 , "foo" : {Version : "v1.2.3" , Github : "foo" }}
4041 versions := tb .Versions ()
4142 Ω (versions .Versions ).Should (HaveLen (2 ))
4243 Ω (versions .Versions ).Should (HaveKey ("abc" ))
0 commit comments