File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed
Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,11 @@ type Git struct {
1515//LSRemote ...
1616//Executes local git ls-remote with params
1717func (os * Git ) LSRemote (argv ... string ) (string , error ) {
18- return os .Run ("git" , "ls-remote" , argv ... )
18+ output , err := os .Run ("git" , "ls-remote" , argv ... )
19+ if err != nil {
20+ return "" , err
21+ }
22+ return strings .TrimSpace (output ), nil
1923}
2024
2125//Branch ...
Original file line number Diff line number Diff line change @@ -11,10 +11,10 @@ var _ = Describe("Remote", func() {
1111
1212 Context ("using github" , func () {
1313 It ("should return organisation and repository with https url" , func () {
14- var https = "https://github.com/Org/sOme--repo .git"
14+ var https = "https://github.com/Praqma/phlow-test-strategy .git"
1515 info := OrgAndRepo (https )
16- Ω (info .Organisation ).Should (Equal ("Org " ))
17- Ω (info .Repository ).Should (Equal ("sOme--repo " ))
16+ Ω (info .Organisation ).Should (Equal ("Praqma " ))
17+ Ω (info .Repository ).Should (Equal ("phlow-test-strategy " ))
1818 })
1919
2020 It ("should return organisation and repository with ssh" , func () {
You can’t perform that action at this time.
0 commit comments